Git Product home page Git Product logo

bamboodle's Introduction

Bamboodle

implements a command that will retrieve authorisation cookies for a bamboo hr session. These cookies can then be used in subsequent scripting

Installation

You must install python-selenium and a suitable driver from AUR (chromedriver)

The command retrieves credentials from password store which should be installed and configured properly

General

  • Arrange for the dependencies in Pipfile to be installed.
$ cd ${REPO_HOME}
$ python3 setup.py install

Arch linux

in package/arch you will find a PKGBUILD file that will build a package suitable for installing with pacman (or more likely a wrapper around pacman, like Yay, that allows installation of AUR packages)

$ cd ${REPO_HOME}/package/arch

# Install AUR package requirements, which are not installed by makepkg -s
$ yay -S python-selenium chromedriver


# Will install dependencies that can be found via pacman
# This will pull the latest version of this repo and build a pacman package, 
# with version related to the git `SHA`
$ makepkg -s .

# Install the package you just built
$ yay -U bamboodle-git*.tar.zst

Usage

Common

Relevant however you invoke the tool.

# If you have a custom domain (can also use -d a-company.bamboohr.com command line option)
$ export BAMBOOHR_DOMAIN=a-company.bamboohr.com 

# Store your credentials in password-store
$ pass insert <username>/${BAMBOOHR_DOMAIN:-bamboohr.com}

Call python directly

$ python3 src/bambdoodle/cookie.py -v <username>
Hunting for cookies for <username>
Logging into https://a-company.bamboohr.com...
Entered username
Entered password
Clicked trust button
DONE
Cookie is:

trusted_browser=XXXXX;lluidt=XXXXX;lluidh=XXXXX;llfn=Bob;lluid=XXXXX;PHPSESSID=XXXXX

Arch linux

# The last line are the cookies you need for scripting.
$ bamboodle -v <username>
Hunting for cookies for <username>
Logging into https://a-company.bamboohr.com...
Entered username
Entered password
Clicked trust button
DONE
Cookie is:

trusted_browser=XXXXX;lluidt=XXXXX;lluidh=XXXXX;llfn=Bob;lluid=XXXXX;PHPSESSID=XXXXX

# default output is just the cookie, to be used for scripting.
$ COOKIE=$(bamboodle <username>)

bamboodle's People

Contributors

sw1nn avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.