-
Notifications
You must be signed in to change notification settings - Fork 11
Improve Repo Sharing Docs #184
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
Open
michaeljguarino
wants to merge
3
commits into
main
Choose a base branch
from
better-encryption-doc
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -9,9 +9,11 @@ The encryption key is automatically generated by Plural and stored in Plural's c | |||||
|
||||||
## Sharing a Plural Git Repository | ||||||
|
||||||
Let's consider a case where Alice wants to share her repository with a teammate Bob. She wants to use our managed age encryption to do that fully securely. There are three steps to this. | ||||||
|
||||||
### Register a public key | ||||||
|
||||||
To register a key for your current machine, run: | ||||||
First, Alice and Bob both need to register age keypairs with plural. To do that register, they should both run this command on their current machine: | ||||||
|
||||||
```shell {% showHeader=false %} | ||||||
plural crypto setup-keys --name <name-for-key-pair> | ||||||
|
@@ -21,7 +23,7 @@ This will generate a new keypair and automatically register the public key with | |||||
|
||||||
### Share the repository | ||||||
|
||||||
To share a repo, use the following command: | ||||||
To share a repo, Alice will run the following command on her already decrypted repo: | ||||||
|
||||||
```shell {% showHeader=false %} | ||||||
plural crypto share --email <email1> --email <email2> | ||||||
|
@@ -41,7 +43,28 @@ If you have the Plural Console deployed, run: | |||||
|
||||||
```shell {% showHeader=false %} | ||||||
plural build --only console | ||||||
plural deploy | ||||||
git add . && git commit -m "set up encryption" | ||||||
plural deploy --commit "set up encryption" | ||||||
``` | ||||||
|
||||||
Regardless, whether the console is installed or not, you should be sure the files written locally were pushed upstream, which can also be done with: | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
|
||||||
``` | ||||||
git add . | ||||||
git commit -m "set up age encryption" | ||||||
git push | ||||||
``` | ||||||
|
||||||
### Bob Decrypts the Repository | ||||||
|
||||||
Now that the keypairs are registered, and repo encryption has moved to using age, Bob should be able to freely decrypt the repo, which is done simply by: | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
|
||||||
```sh | ||||||
git clone <your-git-url> | ||||||
plural crpyto init | ||||||
plural crypto unlock | ||||||
``` | ||||||
|
||||||
### Helpful Hints | ||||||
|
||||||
- Encryption keys are stored locally or in plural's keybackups, so if new teammate gets a new machine, you'll likely need to do this process again for that teammate. | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
- You can also share encryption in a more dirty way using `plural crypto export` and `plural crypto import` |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.