Giter VIP home page Giter VIP logo

docker-lastpass's Introduction

Go Report Card

Sync Lastpass Secret to Docker Secret

Docker lastpass is a binary written in golang to synchronize your lastpass secrets with docker secret.

docker-lastpass use great lastpass-go library.

Requierement

  • Lastpass Account (Free or premium)
  • Docker Swarm (Docker Secret is unavailable in docker standalone)

Usage

./docker-lastpass --config config.toml --username <lastpass-email> --password <lastpass-password>

Options

Parameter Description Required Default
--config Set config file path config.toml
--username Lastpass Username ✔️
--password Lastpass Password ✔️
--otp One Time Password

Configuration File

config.toml example

[log]
level = "debug" # debug,info,warn or error 

[lastpass]
twofactor = "push" # disable,push or OTP 

[secrets]
groups = ["docker"]
lists = []

Secrets In groups add one or more "Folder" name in your lastpass. All secrets of each group will be synchronized.

In list add one or more secret "Name".

Docker Secret

For each lastpass secret 2 docker secrets are created (Username and Password).

For example if your secret name in lastpass is test secret docker-lastpass create secret lastpass_test-secret_Username and lastpass_test-secret_Password

docker secret ls
ID               NAME                            DRIVER        CREATED              UPDATED
bhu3uuyl9nuxxx   lastpass_test-secret_Password                 xx days ago          xx days ago
jn9rqksbf00xxx   lastpass_test-secret_Username                 xx days ago          xx days ago

Limitation

Lastpass API not provide timestamp for edit secret. it is therefore impossible to modify an existing secret. It is therefore to delete the secret in docker so that it can be recreated.

docker-lastpass's People

Contributors

azrod avatar mickaelstanislas avatar

Watchers

 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.