diff --git a/doc/ci/jobs/ssh_keys.md b/doc/ci/jobs/ssh_keys.md index 642f99c86c507b2bbb4976933a107b5400943fea..dc93c40e54fb30ad11ce42fd55b012195fc2c440 100644 --- a/doc/ci/jobs/ssh_keys.md +++ b/doc/ci/jobs/ssh_keys.md @@ -38,9 +38,9 @@ To create and use an SSH key in GitLab CI/CD: at the end of the last line of the SSH key before saving it in the CI/CD settings. 1. Run the [`ssh-agent`](https://linux.die.net/man/1/ssh-agent) in the job, which loads the private key. -1. Copy the public key to the servers you want to have access to (usually in - `~/.ssh/authorized_keys`) or add it as a [deploy key](../../user/project/deploy_keys/index.md) - if you are accessing a private GitLab repository. +1. Copy the public key to the servers you want to have access to (usually in `~/.ssh/authorized_keys`). + If you are accessing a private GitLab repository, you also need to add the public key as + a [deploy key](../../user/project/deploy_keys/index.md). In the following example, the `ssh-add -` command does not display the value of `$SSH_PRIVATE_KEY` in the job log, though it could be exposed if you enable