2024-07-02 22:48:42 -05:00
|
|
|
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json
|
|
|
|
name: Fetch upstream (CDI)
|
|
|
|
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
paths:
|
|
|
|
- .forgejo/workflows/fetch-upstream-cdi.yaml
|
|
|
|
|
|
|
|
env:
|
|
|
|
# renovate: datasource=github-releases depName=kubevirt/containerized-data-importer
|
2024-09-11 12:02:54 -05:00
|
|
|
KUBEVIRTCDI_VERSION: v1.60.3
|
2024-07-02 22:48:42 -05:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
fetch-upstream:
|
|
|
|
runs-on: docker
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2024-07-02 23:03:32 -05:00
|
|
|
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
|
2024-07-02 22:48:42 -05:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
|
|
|
|
- name: Git setup
|
|
|
|
shell: bash
|
|
|
|
run: |
|
|
|
|
git config --global user.name 'Smeagol'
|
|
|
|
git config --global user.email 'smeagol@hsn.dev'
|
|
|
|
|
|
|
|
- name: Fetch files
|
|
|
|
shell: bash
|
|
|
|
run: |
|
2024-07-02 22:49:27 -05:00
|
|
|
git checkout -b cdi-${KUBEVIRTCDI_VERSION} main || git checkout cdi-${KUBEVIRTCDI_VERSION}
|
2024-07-02 22:48:42 -05:00
|
|
|
mkdir ./deploy
|
|
|
|
|
|
|
|
mv ./kustomization-cdi.tmpl.yaml ./deploy/kustomization.yaml
|
|
|
|
curl -vL -o ./deploy/1-cdi-operator.yaml https://github.com/kubevirt/containerized-data-importer/releases/download/${KUBEVIRTCDI_VERSION}/cdi-operator.yaml
|
|
|
|
curl -vL -o ./deploy/2-cdi-cr.yaml https://github.com/kubevirt/containerized-data-importer/releases/download/${KUBEVIRTCDI_VERSION}/cdi-cr.yaml
|
|
|
|
|
|
|
|
git add ./deploy || true
|
|
|
|
git commit -m "feat: cdi-${KUBEVIRTCDI_VERSION}" || true
|
|
|
|
|
|
|
|
git push origin cdi-${KUBEVIRTCDI_VERSION} || true
|