Skip to content

ci: Automated update vc-theme-b2b-vue #689

ci: Automated update vc-theme-b2b-vue

ci: Automated update vc-theme-b2b-vue #689

name: Cloud storybook deployment
on:
workflow_dispatch:
push:
paths:
- 'storybook/**'
branches:
- 'vcst-*'
jobs:
gitops:
runs-on: ubuntu-latest
env:
ARGO_APP_NAME: ${{ github.ref_name }}
STORYBOOK_TAG: ''
steps:
- uses: actions/checkout@v4
- name: Install vc-build
run: |
dotnet tool install --global VirtoCommerce.GlobalTool
- name: Get theme version
id: storybook-version
run: |
echo "STORYBOOK_TAG=$(cat ./storybook/image.json | jq -r '.Tag')" >> $GITHUB_ENV
- name: Update environment
run: |
export PARAMETER_NAME=$(echo "custom.app1.image.tag" | xargs)
export PARAMETER_VALUE=$(echo "${{ env.STORYBOOK_TAG }}" | xargs)
vc-build CloudEnvSetParameter -EnvironmentName ${{ env.ARGO_APP_NAME }} -CloudToken ${{ secrets.VCST_PLATFORM_TOKEN }} -HelmParameters $PARAMETER_NAME=$PARAMETER_VALUE