forked from Equicord/Equicord
-
Notifications
You must be signed in to change notification settings - Fork 0
41 lines (39 loc) · 1.16 KB
/
codeberg-mirror.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
name: Sync to Codeberg
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
on:
push:
workflow_dispatch:
schedule:
- cron: "0 */6 * * *"
jobs:
DetermineRunner:
name: Determine Runner
runs-on: ubuntu-latest
outputs:
runner: ${{ steps.set-runner.outputs.runner }}
steps:
- name: Determine which runner to use
id: set-runner
uses: benjaminmichaelis/get-soonest-available-runner@v1.1.0
with:
primary-runner: "self-hosted"
fallback-runner: "ubuntu-latest"
min-available-runners: 1
github-token: ${{ env.GITHUB_TOKEN }}
env:
GITHUB_TOKEN: ${{ secrets.ETOKEN }}
codeberg:
name: Sync Codeberg and Github
if: github.repository == 'Equicord/Equicord'
needs: DetermineRunner
runs-on: ${{ needs.DetermineRunner.outputs.runner }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: pixta-dev/repository-mirroring-action@674e65a7d483ca28dafaacba0d07351bdcc8bd75 # v1.1.1
with:
target_repo_url: "git@codeberg.org:thororen/Equicord.git"
ssh_private_key: ${{ secrets.CODEBERG }}