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

(PC-33758)(argocd): enable passing extra flags as input #31

Merged
merged 1 commit into from
Jan 7, 2025
Merged
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
6 changes: 5 additions & 1 deletion actions/argocd-sync/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ inputs:
description: Wether or not to use argocd prune option
required: false
default: false
extra_flags:
description: Additional flags that you want to pass to argocd sync
required: false
default: ""

runs:
using: 'composite'
Expand All @@ -46,7 +50,7 @@ runs:
shell: bash
run: |
kubectl config set-context --current --namespace=argocd
argocd_app_sync=(argocd app sync ${{ inputs.app_name }} --core --apply-out-of-sync-only --retry-backoff-duration ${{ inputs.retry_backoff_duration }} --retry-backoff-factor ${{ inputs.retry_backoff_factor }} --retry-backoff-max-duration ${{ inputs.retry_backoff_max_duration }} --timeout ${{ inputs.sync_timeout }})
argocd_app_sync=(argocd app sync ${{ inputs.app_name }} --core --apply-out-of-sync-only --retry-backoff-duration ${{ inputs.retry_backoff_duration }} --retry-backoff-factor ${{ inputs.retry_backoff_factor }} --retry-backoff-max-duration ${{ inputs.retry_backoff_max_duration }} --timeout ${{ inputs.sync_timeout }} ${{ inputs.extra_flags }})
if [ ${{ inputs.prune }} == 'true' ]; then
argocd_app_sync+=(--prune)
fi
Expand Down