Skip to content

Commit 854e84d

Browse files
committed
test
1 parent 77b9280 commit 854e84d

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

.github/workflows/deploy.yml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,13 @@ jobs:
3737
- name: Build list of changed packages and changed adapters
3838
id: changed-adapters
3939
env:
40-
UPSTREAM_BRANCH: main
40+
UPSTREAM_BRANCH: HEAD~1
4141
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4242
run: |
43+
#git fetch --no-tags --depth=1 origin ${{ github.event.pull_request.base.sha }}
4344
./.github/scripts/changed-adapters.sh
45+
echo 'cat $GITHUB_OUTPUT'
46+
cat $GITHUB_OUTPUT
4447
4548
deploy:
4649
name: Trigger infra deployment
@@ -64,12 +67,19 @@ jobs:
6467
aws-lambda-url: ${{ secrets.GATI_LAMBDA_DATA_FEEDS_URL }}
6568
aws-region: ${{ secrets.AWS_REGION }}
6669
aws-role-duration-seconds: '1800' # this is optional and defaults to 900
70+
- name: Determine branch name suffix
71+
id: suffix
72+
run: |
73+
echo "github.event.pull_request.head.ref = ${{ github.event.pull_request.head.ref }}"
74+
if [[ "${{ github.event.pull_request.head.ref }}" = "changeset-release/main" ]]; then
75+
echo "SUFFIX=" >> $GITHUB_OUTPUT
76+
else
77+
echo "SUFFIX=-pr${{ github.event.number }}" >> $GITHUB_OUTPUT
78+
fi
6779
- name: Trigger Image Dispatcher
6880
run: >
6981
gh workflow run
7082
--repo smartcontractkit/infra-k8s
7183
--ref main "Infra-k8s Image Dispatcher"
7284
-F imageRepos="$(echo $CHANGED_ADAPTERS | jq -r "\"$ECR_URL/adapters/\" + (.adapter | .[].shortName) + \"-adapter\"" | tr '\n' ' ')"
73-
-F gitRepo="${{ github.event.repository.name }}-test"
74-
env:
75-
GITHUB_TOKEN: ${{ steps.setup-github-token.outputs.access-token }}
85+
-F gitRepo="${{ github.event.repository.name }}${{ steps.suffix.outputs.SUFFIX }}"

0 commit comments

Comments
 (0)