Coder Social home page Coder Social logo

cerbero's Introduction

Cerbero

Cerbero is a simple program written in python to manage the SSH keys of your remote servers. It reads a config file written in YAML where the keys, remote machines and valid dates are specified and uses that information to log into the machines and regenerate the authorized_keys file.

It is intended to be run on its own and through a cron job every day, so it can delete the expired keys and add the new ones.

Roadmap

  • Push the ssh keys to the remote machines.
  • Merge the authorized_keys with a static file on the remote machine if exists.
  • Apply start and end dates to allow keys to expire.
  • Web interface to modify the config file or maybe a small db.

Development

To run the program directly from the sources, you can use the virtualenv package or you can manage the dependencies manually.

For this second approach, the script run_dev will install the dependencies locally in the deps directory of the repository and will run the main module including those dependencies.

Build the binary

From the repository root directory, first create a dist temporal directory:

mkdir dist

Then install the dependencies locally in that directory:

pip3 install -r requirements.txt --system --upgrade --target dist

And finally, package the whole program into an executable file:

python3 -m zipapp -o cerbero.pyz -p '/usr/bin/env python3' -m cerbero

If you want to install it locally in your system, just move the executable file to a directory in your path:

# You can modify the extension to make it easier to call
sudo mv cerbero.pyz /usr/local/bin/cerbero

cerbero's People

Contributors

mgdelacroix avatar

Stargazers

 avatar

Watchers

 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.