Coder Social home page Coder Social logo

wikimedia-security-deployer-audit's Introduction

DeployersToGSheet

A Python script to get the current list of active WMF deployers via an admin yaml file and store/update within a shared, private Google Sheet.

Prerequisites

python3
argparse
datetime
dotenv
google-api-python-client
pickle
os
re
requests
sys
urllib.parse
yaml

Installing

  1. pip install --upgrade google-api-python-client google-auth-httplib2 google-auth-oauthlib
  2. git clone "https://gerrit.wikimedia.org/r/wikimedia/security/deployer-audit"

Usage

  1. Configure .env to your liking and run something like eval $(cat .env | sed 's/^/export /') - example values provided within sample.env.
  2. Set up Google auth via: https://developers.google.com/sheets/api/quickstart/python
  3. Download credentials.json file from step (2)
  4. Run app, which then prompt you to auth in browser via Google's App Workflow system. This should only need to happen once per install.
  5. chmod +x DeployersToGSheet.py && ./DeployersToGSheet.py {args...}
  6. DeployersToGSheet.py has a few arguments:
    1. -h, --help = show this help message and exit
    2. -p, --phab = Optionally print Phab-formatted table to stdout
    3. -n, --nodeploys = Only print "no deploy" users for Phab-formatted table

Authors

License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details.

wikimedia-security-deployer-audit's People

Contributors

sbassett29 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  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.