-
Notifications
You must be signed in to change notification settings - Fork 6
39 lines (34 loc) · 1.39 KB
/
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
name: "8. Mirror repo"
on:
# Don't mirror every commit to a PR; mirror-on-test-success.yml mirrors when the PR's testing passes
# pull_request:
# branches: [ main, qa, develop ]
# # Limit to certain PR event types since this action could trigger actions to run in the mirror repo
# types: [opened, synchronize, reopened, ready_for_review, review_requested]
# When changes are pushed to special branches
push:
branches: [ main, qa, develop, domain-* ]
# When a Git reference (Git branch or tag) is created
create:
# A PR merge pushes to `develop` and deletes the PR branch, causing this action to be triggered twice.
# So don't trigger on branch delete. Old branches will be deleted on the next mirroring.
# delete:
# Allow manual triggering
workflow_dispatch:
jobs:
to_internal_repo:
# only run this job in the abd-vro repo
if: github.repository == 'department-of-veterans-affairs/abd-vro'
runs-on: ubuntu-latest
steps:
- name: "Checkout source code"
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: "Mirror to internal repo"
uses: yesolutions/mirror-action@v0.6
with:
REMOTE: ssh://git@github.com/department-of-veterans-affairs/abd-vro-internal.git
GIT_USERNAME: ${{ github.actor }}
GIT_SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
GIT_SSH_NO_VERIFY_HOST: "true"