Skip to content

Commit

Permalink
docs: fix init-hoot script for hostname matching
Browse files Browse the repository at this point in the history
The init-hook provided for creating a distrobox with the
the same hostname as its host has two typos:

- Command substitution wrapping `uname -n` suppressing stdout redirect
- trailing "`"

Using this init-hook as suggested causes build errors.
This fix corrects the suggested script by echoing the command
substitution and removing the trailing "`".

See issue #1164 for details.
  • Loading branch information
michaelhaaf committed Feb 7, 2024
1 parent e9bf266 commit d690bef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/useful_tips.md
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ creating it with the following init-hook:

```sh
distrobox create --name test --image your-chosen-image:tag \
--init-hooks '"$(uname -n)" > /etc/hostname'`
--init-hooks 'echo "$(uname -n)" > /etc/hostname'
```

This will ensure SSH X-Forwarding will work when SSH-ing inside the distrobox:
Expand Down

0 comments on commit d690bef

Please sign in to comment.