Skip to content

Commit

Permalink
Merge pull request #154 from wishabi/eks-atomic
Browse files Browse the repository at this point in the history
add --atomic flag
  • Loading branch information
miskiw authored Feb 6, 2024
2 parents bfeb6be + 8c0d474 commit 06e835f
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions deploy/eks/action.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 'eks-deploy'
name: "eks-deploy"
description: 'Custom GitHub action that deploys the repository to EKS using its "/deploy/build.sh" script'

inputs:
Expand Down Expand Up @@ -26,9 +26,12 @@ inputs:
SLACK_BOT_TOKEN:
description: The Slack bot token to pass the data to
required: false
ATOMIC:
description: EKS Atomic Deployment Flag (true or false) - default is true
required: false

runs:
using: 'composite'
using: "composite"
steps:
- name: Set branch variable
id: set-branch
Expand Down Expand Up @@ -62,11 +65,16 @@ runs:
run: |
cmd="chmod +x ./deploy/build.sh && ./deploy/build.sh service deploy_eks --env=${{ inputs.ENV }}"
# Check if timeout is set and provide it as a flag
# Check if TIMEOUT is set and provide it as a flag
if [ -n "${{ inputs.TIMEOUT }}" ]; then
cmd="${cmd} --timeout=${{ inputs.TIMEOUT }}"
fi
# Check if ATOMIC is set and provide it as a flag
if [ -n "${{ inputs.ATOMIC }}" ]; then
cmd="${cmd} --atomic=${{ inputs.ATOMIC }}"
fi
# Execute command
eval $cmd
- name: Notify slack channel on success
Expand Down

0 comments on commit 06e835f

Please sign in to comment.