feat(vmop): first implementation (#4) #1
Workflow file for this run
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
name: Build and push for prod | |
env: | |
MODULES_REGISTRY: ${{ vars.PROD_REGISTRY }} | |
CI_COMMIT_REF_NAME: ${{ github.ref_name }} | |
MODULES_MODULE_NAME: ${{ vars.MODULE_NAME }} | |
MODULE_SOURCE_NAME: ${{ vars.PROD_MODULE_SOURCE_NAME }} | |
MODULES_REGISTRY_LOGIN: ${{ vars.PROD_MODULES_REGISTRY_LOGIN }} | |
MODULES_REGISTRY_PASSWORD: ${{ secrets.PROD_MODULES_REGISTRY_PASSWORD }} | |
MODULES_MODULE_TAG: ${{ github.ref_name }} | |
on: | |
push: | |
tags: | |
- 'v[0-9]+.[0-9]+.[0-9]+' | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
prod_ce_setup_build: | |
runs-on: ubuntu-latest | |
name: Build and Push CE | |
steps: | |
- name: SET VAR | |
run: | | |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/ce/modules" >> "$GITHUB_ENV" | |
- run: | | |
echo $MODULES_REGISTRY | |
echo $MODULES_MODULE_NAME | |
echo $MODULES_MODULE_SOURCE | |
echo $MODULES_MODULE_TAG | |
shell: bash | |
name: Show vars | |
- uses: actions/checkout@v4 | |
- uses: deckhouse/modules-actions/setup@v1 | |
- uses: deckhouse/modules-actions/build@v1 | |
- name: Register the module | |
run: | | |
echo "✨ Register the module ${MODULES_MODULE_NAME}" | |
crane append \ | |
--oci-empty-base \ | |
--new_layer "" \ | |
--new_tag "${MODULES_MODULE_SOURCE}:${MODULES_MODULE_NAME}" | |
shell: bash | |
prod_ee_setup_build: | |
runs-on: ubuntu-latest | |
name: Build and Push EE | |
steps: | |
- name: SET VAR | |
run: | | |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/ee/modules" >> "$GITHUB_ENV" | |
- run: | | |
echo $MODULES_REGISTRY | |
echo $MODULES_MODULE_NAME | |
echo $MODULES_MODULE_SOURCE | |
echo $MODULES_MODULE_TAG | |
shell: bash | |
name: Show vars | |
- uses: actions/checkout@v4 | |
- uses: deckhouse/modules-actions/setup@v1 | |
- uses: deckhouse/modules-actions/build@v1 | |
- name: Register the module | |
run: | | |
echo "✨ Register the module ${MODULES_MODULE_NAME}" | |
crane append \ | |
--oci-empty-base \ | |
--new_layer "" \ | |
--new_tag "${MODULES_MODULE_SOURCE}:${MODULES_MODULE_NAME}" | |
shell: bash | |
prod_fe_setup_build: | |
runs-on: ubuntu-latest | |
name: Build and Push FE | |
steps: | |
- name: SET VAR | |
run: | | |
echo "MODULES_MODULE_SOURCE=$MODULES_REGISTRY/$MODULE_SOURCE_NAME/fe/modules" >> "$GITHUB_ENV" | |
- run: | | |
echo $MODULES_REGISTRY | |
echo $MODULES_MODULE_NAME | |
echo $MODULES_MODULE_SOURCE | |
echo $MODULES_MODULE_TAG | |
shell: bash | |
name: Show vars | |
- uses: actions/checkout@v4 | |
- uses: deckhouse/modules-actions/setup@v1 | |
- uses: deckhouse/modules-actions/build@v1 | |
- name: Register the module | |
run: | | |
echo "✨ Register the module ${MODULES_MODULE_NAME}" | |
crane append \ | |
--oci-empty-base \ | |
--new_layer "" \ | |
--new_tag "${MODULES_MODULE_SOURCE}:${MODULES_MODULE_NAME}" | |
shell: bash |