README: update gokrazy instructions
This commit is contained in:
parent
2c1eed342d
commit
95ac9a06f8
56
README.md
56
README.md
@ -15,32 +15,46 @@ started via the gokrazy web interface.
|
|||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
Please see https://gokrazy.org/quickstart/ if you’re unfamiliar with gokrazy.
|
Please see [the gokrazy quickstart
|
||||||
|
instructions](https://gokrazy.org/quickstart/) if you’re unfamiliar with
|
||||||
|
gokrazy.
|
||||||
|
|
||||||
First, install your SSH public key(s) as authorized via [package
|
When creating a new gokrazy instance, the `gok new` command automatically
|
||||||
config](https://gokrazy.org/userguide/package-config/) for the
|
installs `breakglass` and [authorizes
|
||||||
`github.com/gokrazy/breakglass` package:
|
`~/.ssh/id_*.pub`](https://github.com/gokrazy/tools/blob/b89d9dc6e09742ea23492bb84021da70b2965bff/cmd/gok/cmd/new.go#L124).
|
||||||
|
|
||||||
|
If you want to repeat this installation for some reason, use:
|
||||||
|
|
||||||
```
|
```
|
||||||
mkdir -p extrafiles/github.com/gokrazy/breakglass/etc/
|
gok add github.com/gokrazy/breakglass
|
||||||
# Note: At the moment only ed25519 and ecdsa keys work
|
gok add github.com/gokrazy/serial-busybox
|
||||||
cat ~/.ssh/id_*.pub \
|
|
||||||
> extrafiles/github.com/gokrazy/breakglass/etc/breakglass.authorized_keys
|
|
||||||
|
|
||||||
mkdir -p flags/github.com/gokrazy/breakglass/
|
|
||||||
echo '-authorized_keys=/etc/breakglass.authorized_keys' \
|
|
||||||
> flags/github.com/gokrazy/breakglass/flags.txt
|
|
||||||
```
|
```
|
||||||
|
|
||||||
Then, add the `github.com/gokrazy/breakglass` and
|
Then, create an [`authorized_keys(5)`
|
||||||
`github.com/gokrazy/serial-busybox` packages to your `gokr-packer` command,
|
file](https://manpages.debian.org/authorized_keys.5) in
|
||||||
e.g.:
|
`breakglass.authorized_keys` and install it as an extrafile:
|
||||||
|
|
||||||
```
|
```json
|
||||||
gokr-packer -overwrite=/dev/sdx \
|
{
|
||||||
github.com/gokrazy/hello \
|
"Hostname": "hello",
|
||||||
github.com/gokrazy/serial-busybox \
|
"Packages": [
|
||||||
github.com/gokrazy/breakglass
|
"github.com/gokrazy/fbstatus",
|
||||||
|
"github.com/gokrazy/hello",
|
||||||
|
"github.com/gokrazy/serial-busybox",
|
||||||
|
"github.com/gokrazy/breakglass"
|
||||||
|
],
|
||||||
|
"PackageConfig": {
|
||||||
|
"github.com/gokrazy/breakglass": {
|
||||||
|
"CommandLineFlags": [
|
||||||
|
"-authorized_keys=/etc/breakglass.authorized_keys"
|
||||||
|
],
|
||||||
|
"ExtraFilePaths": {
|
||||||
|
"/etc/breakglass.authorized_keys": "/home/michael/gokrazy/repro/breakglass.authorized_keys"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"SerialConsole": "disabled"
|
||||||
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
@ -48,7 +62,7 @@ gokr-packer -overwrite=/dev/sdx \
|
|||||||
Be sure to install the convenience SSH wrapper tool on the host:
|
Be sure to install the convenience SSH wrapper tool on the host:
|
||||||
|
|
||||||
```
|
```
|
||||||
go install github.com/gokrazy/breakglass/cmd/breakglass
|
go install github.com/gokrazy/breakglass/cmd/breakglass@latest
|
||||||
```
|
```
|
||||||
|
|
||||||
### Start a shell
|
### Start a shell
|
||||||
|
Loading…
x
Reference in New Issue
Block a user