Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(js): corrected use of stageDependencies in the deployment stage #18

Merged
merged 1 commit into from
Feb 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ Exceptions are acceptable depending on the circumstances (critical bug fixes tha
- corrected the way the delivery and deployment steps are skipped or not in Azure DevOps
- corrected GoLang delivery and deployment to have the default image and the proper format
- changed Javascript deployment to continue tasks with error
- corrected use of `stageDependencies` in the deployment stage

### Removed

Expand Down
6 changes: 4 additions & 2 deletions azure-devops/javascript/stages/50-deployment/k8s.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ stages:
- stage: 'deployment'
condition: or(eq(variables['Build.SourceBranch'], 'refs/heads/main'), startsWith(variables['Build.SourceBranch'], 'refs/tags/'))
displayName: 'deployment'
dependsOn: 'delivery'
variables:
dockerContainerTag: $[stageDependencies.delivery.delivery.outputs['build.DOCKER_CONTAINER_TAG']]
jobs:
- job: 'deployment'
displayName: 'deployment'
Expand Down Expand Up @@ -66,8 +69,7 @@ stages:
kubernetesServiceEndpoint: '$(K8S_ENDPOINT)'
namespace: '$(K8S_NAMESPACE)'
command: 'set'
# TODO: this output is not being parsed correctly
arguments: "image deployment/$(K8S_DEPLOYMENT_NAME) $(K8S_CONTAINER_NAME)=$(DOCKER_CONTAINER_IMAGE):$(stageDependencies.delivery.delivery.outputs['build.DOCKER_CONTAINER_TAG'])"
arguments: "image deployment/$(K8S_DEPLOYMENT_NAME) $(K8S_CONTAINER_NAME)=$(DOCKER_CONTAINER_IMAGE):$(dockerContainerTag)"
# TODO: this command below should wait for the deployment to be ready
- task: Kubernetes@1
inputs:
Expand Down