
4

搭建 Github 私有 Runner
source link: https://liqiang.io/post/build-your-github-private-runner-ee6ba45a
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

搭建 Github 私有 Runner
@SOLUTION· 2024-04-20 08:21 · 14 min read
[[email protected]]# yum install perl-Digest-SHA -y
[[email protected]]# mkdir actions-runner && cd actions-runner
[[email protected]]# curl -o actions-runner-linux-x64-2.312.0.tar.gz -L https://github.com/actions/runner/releases/download/v2.312.0/actions-runner-linux-x64-2.312.0.tar.gz
[[email protected]]# echo "85c1bbd104d539f666a89edef70a18db2596df374a1b51670f2af1578ecbe031 actions-runner-linux-x64-2.312.0.tar.gz" | shasum -a 256 -c
[[email protected]]# tar xzf ./actions-runner-linux-x64-2.312.0.tar.gz
[[email protected]]# ./config.sh --url https://github.com/liuliqiang/laumonkey --token <token>
[[email protected]]# sudo ./svc install
启动 runner
[[email protected]]# sudo chcon system_u:object_r:usr_t:s0 runsvc.sh
[[email protected]]# sudo ./svc.sh start
图 :这个是图片说明 |
---|
![]() |
查看 runner 状态
- 打开你的 repo,然后选择 settings
图 :这个是图片说明 |
---|
![]() |
- 查看你的 runner 状态
图 :这个是图片说明 |
---|
![]() |
这个状态可能是:
- Idle: The runner is connected to GitHub and is ready to execute jobs.
- Active: The runner is currently executing a job.
- Offline: The runner is not connected to GitHub. This could be because the machine is offline, the self-hosted runner application is not running on the machine, or the self-hosted runner application cannot communicate with GitHub.
- 使用自建 runner
直接在 action 的配置文件中,指定 runs-on: self-hosted
就可以让自建的 action 来运行你的 Github Action 了。
图 :这个是图片说明 |
---|
![]() |
</article
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK