Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add swarm key variables to container daemon #6554

Merged
merged 2 commits into from
Aug 7, 2019

Conversation

Caian
Copy link
Contributor

@Caian Caian commented Aug 2, 2019

Modify the container daemon to allow an external swarm key to be assigned to /data/ipfs/swarm.key during container initialization. The environment variables are:

  • IPFS_SWARM_KEY
  • IPFS_SWARM_KEY_FILE

The IPFS_SWARM_KEY creates swarm.key with the content of the variable itself, whilst IPFS_SWARM_KEY_FILE copies the key from a path referred by the variable. This enables, for instance, docker secrets support.

The IPFS_SWARM_KEY_FILE overwrites the key generated by IPFS_SWARM_KEY.

The key generated by both variables has permission 0400 (u+r, go-rwx)


License: MIT
Signed-off-by: Caian Benedicto [email protected]

Caian added 2 commits August 2, 2019 16:28
License: MIT
Signed-off-by: Caian Benedicto <[email protected]>
License: MIT
Signed-off-by: Caian Benedicto <[email protected]>
Copy link
Member

@Stebalien Stebalien left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! LGTM!

@Stebalien Stebalien merged commit 7066042 into ipfs:master Aug 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants