-
Notifications
You must be signed in to change notification settings - Fork 66
chore: add note about ssh passphrase when mounting bashrc #1313
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
Conversation
|
@dkwon17 thanks for the PR :) will review shortly |
|
CI is failing due to #1314 |
AObuchow
left a comment
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.
docs/additional-configuration.adoc
Outdated
| --from-literal=passphrase="$PASSPHRASE" | ||
| ---- | ||
| + | ||
| Note: If a passphrase is provided, the DevWorkspace operator adds a postStart event that starts the SSH agent and adds the passphrase. |
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.
For consistency with the rest of the document: "DevWorkspace operator" -> "DevWorkspace Operator"
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.
Also, maybe we should bold "Note:"?
i.e. Note: -> *Note:*
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.
Fixed, I've also updated all Note: do be bold
docs/additional-configuration.adoc
Outdated
| ---- | ||
| + | ||
| Note: If a passphrase is provided, the DevWorkspace operator adds a postStart event that starts the SSH agent and adds the passphrase. | ||
| The DevWorkspace operator also modifies the bashrc file to configure the `SSH_AGENT_PID` and `SSH_AUTH_SOCK` environment variables. |
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.
- "operator" should also be capitalized here for consistency
- Maybe we should replace all mentions of "bashrc" with
`~/.bashrc`?
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.
Fixed both
docs/additional-configuration.adoc
Outdated
| Note: If a passphrase is provided, the DevWorkspace operator adds a postStart event that starts the SSH agent and adds the passphrase. | ||
| The DevWorkspace operator also modifies the bashrc file to configure the `SSH_AGENT_PID` and `SSH_AUTH_SOCK` environment variables. | ||
| If you are automatically mounting your own bashrc file with a ConfigMap (see link:additional-configuration.adoc#automatically-mounting-volumes-configmaps-and-secrets[Automatically mounting volumes, configmaps, and secrets]) | ||
| you must add the following in your bashrc file: |
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.
I would suggest changing in your .bashrc file: to to your ~/.bashrc:. Though this is just a suggestion -- the way you currently have it makes sense 👍
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.
Fixed
docs/additional-configuration.adoc
Outdated
| + | ||
| [source,bash] | ||
| ---- | ||
| [ -f /home/user/ssh-environment ] && source /home/user/ssh-environment |
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.
In the implementation of the postStart event, $HOME is used instead of /home/user/ as the workspace may be using a different image than the UDI, which may have a different value for $HOME.
So maybe this should instead be:
[ -f $HOME/ssh-environment ] && source $HOME/ssh-environment
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.
Fixed
Signed-off-by: dkwon17 <dakwon@redhat.com>
AObuchow
left a comment
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.
Last comment, then this will be good to merge (just remember to squash your changes). Feel free to just amend your last commit & squash things so that we can merge ASAP :)
docs/additional-configuration.adoc
Outdated
| ---- | ||
| + | ||
| *Note:* If a passphrase is provided, the DevWorkspace Operator adds a postStart event that starts the SSH agent and adds the passphrase. | ||
| The DevWorkspace operator also modifies the `~/.bashrc` to configure the `SSH_AGENT_PID` and `SSH_AUTH_SOCK` environment variables. |
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.
Sorry for the last nitpick: "operator" should also be capitalized here, i.e. "The DevWorkspace Operator"
AObuchow
left a comment
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.
Looks good to me, great work David thanks for getting this done :)
Please squash your last two "update" commits into the first commit, and merge this when you have a chance 👍
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: AObuchow, dkwon17 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Fix devfile#1317 Signed-off-by: dkwon17 <dakwon@redhat.com>
What does this PR do?
Adds documentation about ssh passphrase when automounting bashrc with a configmap
What issues does this PR fix or reference?
#1317
Is it tested? How?
PR Checklist
/test v8-devworkspace-operator-e2e, v8-che-happy-pathto trigger)v8-devworkspace-operator-e2e: DevWorkspace e2e testv8-che-happy-path: Happy path for verification integration with Che