chore(devfile) link v2 devfile to :3.17; set image refs to registry.r… #41
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
# | |
# Copyright (c) 2022 Red Hat, Inc. | |
# This program and the accompanying materials are made | |
# available under the terms of the Eclipse Public License 2.0 | |
# which is available at https://www.eclipse.org/legal/epl-2.0/ | |
# | |
# SPDX-License-Identifier: EPL-2.0 | |
# | |
name: Rebuild Devfile Registry | |
on: | |
push: | |
branches: | |
- 'devspaces-[0-9].[0-9]+-rhel-8' | |
- devspaces-3-rhel-8 | |
jobs: | |
publish: | |
name: publish | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Trigger rebuild of devfile registry | |
env: | |
GITHUB_TOKEN: ${{ secrets.CRW_BUILD_TOKEN }} | |
run: | | |
export GITHUB_TOKEN=${{ secrets.CRW_BUILD_TOKEN }} | |
git clone -b "$GITHUB_REF_NAME" "https://github.com/redhat-developer/devspaces.git" ds | |
cd ds | |
git config user.email "[email protected]" | |
git config user.name "devstudio-release" | |
git config --global push.default matching | |
git config --global pull.rebase true | |
git config --global hub.protocol https | |
git remote set-url origin https://$GITHUB_TOKEN:[email protected]/redhat-developer/devspaces.git | |
sed -i -r -e "s@^Webhook triggered on: .+@Webhook triggered on: $(date) [$GITHUB_REPOSITORY] @" dependencies/che-devfile-registry/webhook_trigger.txt | |
git commit -m "chore: update webhook_trigger.txt for $GITHUB_REPOSITORY @ $GITHUB_REF_NAME" dependencies/che-devfile-registry/webhook_trigger.txt | |
git pull origin "$GITHUB_REF_NAME" || true | |
git push origin "$GITHUB_REF_NAME" |