forked from thanos-community/thanos-operator
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #23 from rhobs/gh_workflow
Gh workflow
- Loading branch information
Showing
1 changed file
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 |