23 lines
No EOL
735 B
YAML
23 lines
No EOL
735 B
YAML
stages:
|
|
- update_patched_master
|
|
|
|
variables:
|
|
GIT_STRATEGY: fetch
|
|
GIT_SSL_NO_VERIFY: "1"
|
|
|
|
update_patched_master:
|
|
stage: update_patched_master
|
|
only:
|
|
- patched_changes
|
|
script:
|
|
- apk add --no-cache git
|
|
- git config user.name "$GITLAB_USER_NAME"
|
|
- git config user.email "$GITLAB_USER_EMAIL"
|
|
- git remote set-url origin http://oauth2:${GITLAB_ACCESS_TOKEN}@172.17.0.1:4411/${CI_PROJECT_PATH}.git
|
|
- echo "Fetching all branches..."
|
|
- git fetch --all
|
|
- echo "Resetting patched_master to patched_changes..."
|
|
- git checkout patched_master
|
|
- git reset --hard origin/patched_changes
|
|
- echo "Force-pushing patched_master to match patched_changes..."
|
|
- git push origin patched_master --force |