Skip to content

Commit 12f78d8

Browse files
committed
Corrections, typos
1 parent 36b986f commit 12f78d8

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

docs/remote/troubleshooting.md

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,6 @@ icacls "%FILEORFOLDERTOUPDATE%" /c /inheritance:r /grant %USERDOMAIN%\%USERNAME%
237237
|----|--------------|---|
238238
| Debian / Ubuntu | Run `sudo apt-get install openssh-server` | See the [Ubuntu SSH](https://help.ubuntu.com/community/SSH?action=show) documentation for additional setup instructions. |
239239
| RHEL / Fedora / CentOS | Run `sudo yum install openssh-server && sudo systemctl start sshd.service && sudo systemctl enable sshd.service` | You may need to omit `sudo` when running in a container. |
240-
| macOS | Go to **System Preferences** > **Sharing**, check **Remote Login**. ||
241240

242241
## Container tips
243242

@@ -400,7 +399,7 @@ You can use Docker and Kubernetes related CLIs and extensions from inside your d
400399

401400
### Adding a non-root user to your dev container
402401

403-
Many images run as a root user by default. However, some provide non-root users, that you can optionally use instead. If your image or Dockerfile provides a non-root user that you can opt into using (for example, the default is still root), you can specify the user in one of two ways:
402+
Many images run as a root user by default. However, some provide one or more non-root users, that you can optionally use instead. If your image or Dockerfile provides a non-root user (but still defaults to root), you can opt into using it in one of two ways:
404403

405404
- When referencing an `image` or `Dockerfile`, add the following to your `devcontainer.json`:
406405

@@ -414,9 +413,7 @@ Many images run as a root user by default. However, some provide non-root users,
414413
user: user-name-goes-here
415414
```
416415

417-
Note that you do not need to do this if the default behavior of the container is to use the non-root user.
418-
419-
For images that only provide a root user, you can automatically create a non-root user in the `Dockerfile`. For example, this snippet will create a user called `user-name-goes-here` and give it the ability to use `sudo`:
416+
For images that only provide a root user, you can automatically create a non-root user by using a `Dockerfile`. For example, this snippet will create a user called `user-name-goes-here`, give it the ability to use `sudo`, and set it as the default:
420417

421418
```Dockerfile
422419
ARG USERNAME=user-name-goes-here
@@ -496,7 +493,7 @@ This warning is just that, a warning. It is telling you not to parse the output
496493
This occurs in `Dockerfile`s because the `apt-key` command is not running from a terminal. Unfortunately, this error cannot be eliminated completely, but can be hidden unless the `apt-key` command returns a non-zero exit code (indicating a failure). For example:
497494

498495
```Dockerfile
499-
# (OUT=$(apt-key add - 2>&1) || echo $OUT) will only print the output if a non-zero exit code is hit
496+
# (OUT=$(apt-key add - 2>&1) || echo $OUT) will only print the output with non-zero exit code is hit
500497
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | (OUT=$(apt-key add - 2>&1) || echo $OUT)
501498
```
502499

0 commit comments

Comments
 (0)