1
0
Fork 0
mirror of https://code.forgejo.org/infrastructure/documentation synced 2024-11-21 11:01:15 +00:00

runner: instructions to install docuum

This commit is contained in:
Earl Warren 2024-11-07 15:20:28 +01:00
parent 5abb755a06
commit 171f9638c4
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -10,7 +10,7 @@ The runners it contains are not started at boot, it must be done manually. The b
### Installation
```shell
version=3.5.0
version=4.0.1
sudo wget -O /usr/local/bin/forgejo-runner-$version https://code.forgejo.org/forgejo/runner/releases/download/v$version/forgejo-runner-$version-linux-amd64
sudo chmod +x /usr/local/bin/forgejo-runner-$version
echo 'export TERM=xterm-256color' >> .bashrc
@ -35,10 +35,33 @@ containers, the labels in `config.yml` should be
```shell
name=myrunner
mkdir -p $DIR ; cd $DIR
forgejo-runner generate-config > config-$name.yml
forgejo-runner-$version generate-config > config-$name.yml
## edit config-$name.yml and adjust the `labels:`
## Obtain a $TOKEN from https://$DIR
forgejo-runner-$version register --no-interactive --token $TOKEN --name runner --instance https://codeberg.org
forgejo-runner-$version --config config-$name.yml daemon |& cat -v > runner.log &
```
### Removing old docker images
[docuum](https://github.com/stepchowfun/docuum)
```sh
curl https://raw.githubusercontent.com/stepchowfun/docuum/main/install.sh -LSfs | sh
sudo tee /etc/systemd/system/docuum.service <<'EOF'
[Unit]
Description=Docuum
After=docker.service
Wants=docker.service
[Service]
Environment='THRESHOLD=10 GB'
ExecStart=/usr/local/bin/docuum --threshold ${THRESHOLD}
Restart=on-failure
[Install]
WantedBy=multi-user.target
EOF
sudo systemctl enable docuum --now
sudo journalctl --follow --unit docuum
```