diff --git a/back/readme.md b/back/readme.md index c93f079..c47d1b8 100644 --- a/back/readme.md +++ b/back/readme.md @@ -1,10 +1,42 @@ ## runner ``` -RUNNER_ALLOW_RUNASROOT="1" ./config.sh +export RUNNER_ALLOW_RUNASROOT=1 ``` ``` -export RUNNER_ALLOW_RUNASROOT="1" -nohup ./run.sh >/dev/null 2>&1 +./config.sh xxxxxxxxxxxxxxxxxxxxxxx +``` + +``` +nano /etc/systemd/system/github-runner.service +``` + +``` +[Unit] +Description=GitHub Actions Runner + +[Service] +Type=simple +WorkingDirectory=/root/actions-runner +ExecStart=/root/actions-runner/run.sh +User=root +Restart=always +Environment="RUNNER_ALLOW_RUNASROOT=1" + +[Install] +WantedBy=multi-user.target +``` + +``` +sudo systemctl daemon-reload +sudo systemctl start github-runner +``` + +``` +sudo systemctl status github-runner +``` + +``` +sudo systemctl enable github-runner ```