Skip to content

Commit

Permalink
test: pr
Browse files Browse the repository at this point in the history
  • Loading branch information
cterence committed Jan 19, 2025
1 parent cfcce21 commit f2f4a42
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
14 changes: 11 additions & 3 deletions .github/workflows/pr-argo-diff.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Set up environment
run: |
Expand All @@ -21,9 +23,15 @@ jobs:
- name: Get updated charts
id: updated-charts
run: |
UPDATED_APPS=$(git diff --name-only origin/main...HEAD | grep '^k8s-apps/' | awk -F'/' '{print $2}' | sort -u)
echo "Updated charts: $UPDATED_APPS"
echo "::set-output name=apps::$UPDATED_APPS"
git fetch origin # Ensure the latest refs are fetched
MODIFIED_APPS=$(git diff --name-only origin/main...HEAD | xargs)
if [ -z "$MODIFIED_APPS" ]; then
echo "No changes detected"
echo "apps=" >> $GITHUB_OUTPUT
else
echo "Modified apps: $MODIFIED_APPS"
echo "apps=$MODIFIED_APPS" >> $GITHUB_OUTPUT
fi
- name: Login to ArgoCD
if: steps.updated-charts.outputs.apps != ''
Expand Down
2 changes: 1 addition & 1 deletion k8s-apps/argocd/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ argo-cd:
# paths:
# - /argocd(/|$)(.*)
hostname:
argocd.terence.cloud
argocd.terence.clouds
# - k8s-ingress.snow-delta.ts.net
tls: true
ingressClassName: nginx
Expand Down

0 comments on commit f2f4a42

Please sign in to comment.