mirror of
https://github.com/simstudioai/sim.git
synced 2026-01-09 23:17:59 -05:00
fix(ci): capture correct deployment version output (#1512)
* Capture correct deployment version output * Add trigger access token to each step * Use correct arn
This commit is contained in:
committed by
GitHub
parent
561b6f2778
commit
c1a3500bde
12
.github/workflows/trigger-deploy.yml
vendored
12
.github/workflows/trigger-deploy.yml
vendored
@@ -44,17 +44,17 @@ jobs:
|
|||||||
if: github.ref == 'refs/heads/staging'
|
if: github.ref == 'refs/heads/staging'
|
||||||
id: deploy-staging
|
id: deploy-staging
|
||||||
working-directory: ./apps/sim
|
working-directory: ./apps/sim
|
||||||
|
env:
|
||||||
|
TRIGGER_ACCESS_TOKEN: ${{ secrets.TRIGGER_ACCESS_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
npx --yes trigger.dev@4.0.4 deploy -e staging --skip-promotion
|
npx --yes trigger.dev@4.0.4 deploy -e staging --skip-promotion
|
||||||
echo "version=$TRIGGER_DEPLOYMENT_VERSION" >> $GITHUB_OUTPUT
|
|
||||||
echo "Deployed version: $TRIGGER_DEPLOYMENT_VERSION"
|
|
||||||
|
|
||||||
- name: Store Staging version in Parameter Store
|
- name: Store Staging version in Parameter Store
|
||||||
if: github.ref == 'refs/heads/staging'
|
if: github.ref == 'refs/heads/staging'
|
||||||
run: |
|
run: |
|
||||||
aws ssm put-parameter \
|
aws ssm put-parameter \
|
||||||
--name "${{ secrets.TRIGGER_VERSION_SECRET_MANAGER_STAGING }}" \
|
--name "${{ secrets.TRIGGER_VERSION_SECRET_MANAGER_STAGING }}" \
|
||||||
--value "${{ steps.deploy-staging.outputs.version }}" \
|
--value "${{ steps.deploy-staging.outputs.deploymentVersion }}" \
|
||||||
--type "String" \
|
--type "String" \
|
||||||
--overwrite
|
--overwrite
|
||||||
|
|
||||||
@@ -62,16 +62,16 @@ jobs:
|
|||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/main'
|
||||||
id: deploy-production
|
id: deploy-production
|
||||||
working-directory: ./apps/sim
|
working-directory: ./apps/sim
|
||||||
|
env:
|
||||||
|
TRIGGER_ACCESS_TOKEN: ${{ secrets.TRIGGER_ACCESS_TOKEN }}
|
||||||
run: |
|
run: |
|
||||||
npx --yes trigger.dev@4.0.4 deploy --skip-promotion
|
npx --yes trigger.dev@4.0.4 deploy --skip-promotion
|
||||||
echo "version=$TRIGGER_DEPLOYMENT_VERSION" >> $GITHUB_OUTPUT
|
|
||||||
echo "Deployed version: $TRIGGER_DEPLOYMENT_VERSION"
|
|
||||||
|
|
||||||
- name: Store Production version in Parameter Store
|
- name: Store Production version in Parameter Store
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.ref == 'refs/heads/main'
|
||||||
run: |
|
run: |
|
||||||
aws ssm put-parameter \
|
aws ssm put-parameter \
|
||||||
--name "${{ secrets.TRIGGER_VERSION_SECRET_MANAGER_PROD }}" \
|
--name "${{ secrets.TRIGGER_VERSION_SECRET_MANAGER_PROD }}" \
|
||||||
--value "${{ steps.deploy-production.outputs.version }}" \
|
--value "${{ steps.deploy-production.outputs.deploymentVersion }}" \
|
||||||
--type "String" \
|
--type "String" \
|
||||||
--overwrite
|
--overwrite
|
||||||
Reference in New Issue
Block a user