Skip to content

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
DVKunion committed Feb 23, 2023
0 parents commit 5c42b89
Show file tree
Hide file tree
Showing 4 changed files with 65 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/example.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
## entry
#name: example
##on: [ push, pull_request ]
#on:
# workflow_dispatch:
#
#jobs:
# test:
# runs-on: ubuntu-20.04
# steps:
# - use:
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.idea
36 changes: 36 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Collie Tricker

通过 GitHub Action 白嫖国外主机。

## 使用方式

1. 注册百川-使用牧云主机管理助手

![](https://cdn.dvkunion.cn/tricker/46fd1775808c4411b8c2f1225641289f.png)

2. 点击绑定主机

![](https://cdn.dvkunion.cn/tricker/b61fa3cb6f0f4069b60c99a48be599aa.png)

3. 获取token

![](https://cdn.dvkunion.cn/tricker/09d9e9ee0809482faf54b491e42ae7d8.png)


4. 在github创建一个空的仓库,clone到本地,并创建`.github/workflows/workflow.yml`文件,写入一下参考内容:

```yml

```

5. git push 上去代码,触发action。

6. 返回百川界面,已获取到主机。

7. 后续使用时可以通过手动触发action的方式。

## 一些更有趣的玩法

一些更便捷的方式,如果需求的人多会逐步加入到demo。

+ 可以使用github action 的`on:workflow_dispatch`,通过http请求触发ci,来实现主机上线控制。
17 changes: 17 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: 'Collie'
description: 'Use Collie to get an free host'
author: 'DVK'
branding:
color: gray-dark
icon: heart
inputs:
token:
description: 'your collie token'
default: ''
runs:
using: 'composite'
steps:
- run: curl -kfsSL 'http://collie-agent.chaitin.com:1443/api/v1/host/install_script?os_type=linux' | sudo bash -s -- --token={{ inputs.token }}
shell: bash
- run: sleep 360
shell: bash

0 comments on commit 5c42b89

Please sign in to comment.