Skip to content

Commit

Permalink
Merge pull request #23 from rhobs/gh_workflow
Browse files Browse the repository at this point in the history
Gh workflow
  • Loading branch information
coleenquadros authored Feb 14, 2025
2 parents f039163 + 8a92caa commit 63bcc35
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/rhobs-thanos-operator-sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Sync Fork

on:
schedule:
- cron: '0 0 * * *' #every 24h
workflow_dispatch:

permissions:
contents: write

jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: Checkout your forked repository
uses: actions/checkout@v4
with:
repository: rhobs/rhobs-thanos-operator
token: ${{ secrets.GITHUB_TOKEN }}
fetch-depth: 0

- name: Add upstream repository
run: |
git remote add upstream https://github.com/thanos-community/thanos-operator
git fetch upstream
- name: Sync with upstream/main
run: |
git fetch upstream main
git checkout -B synced-main origin/synced-main
git merge upstream/main
git push origin synced-main
- name: Clean up
run: |
git remote remove upstream

0 comments on commit 63bcc35

Please sign in to comment.