Skip to content

Commit 5677d82

Browse files
committed
fix: deploy to stacks enabled
1 parent b5f7317 commit 5677d82

1 file changed

Lines changed: 18 additions & 11 deletions

File tree

.github/workflows/release-flask.yml

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,15 @@ on:
2525
stacks-repo:
2626
type: string
2727
required: false
28-
default: "git@github.com:coingaming/stacks.git"
28+
default: "coingaming/stacks"
2929
stacks-name:
3030
type: string
3131
required: false
3232
default: ${{ inputs.app-name }}
33+
stacks-branch-name:
34+
type: string
35+
required: false
36+
default: ${{ inputs.app-name }}
3337
app-name:
3438
type: string
3539
required: true
@@ -99,6 +103,9 @@ jobs:
99103
# with:
100104
# node-version: 20.10.0
101105

106+
- name: Install yq
107+
run: sudo apt-get install yq
108+
102109
- name: Add NPM Registry
103110
run: echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > .npmrc
104111

@@ -107,8 +114,8 @@ jobs:
107114
GH_PAT: ${{ secrets.GH_TOKEN }}
108115
GIT_TERMINAL_PROMPT: 0
109116
run: |
110-
git config --global --replace-all url."https://${GH_PAT}@github.com/".insteadOf git@github.com:
111-
git config --global --add url."https://${GH_PAT}@github.com/".insteadOf "https://github.com/"
117+
git config --global user.email "actions@github.com"
118+
git config --global user.name ${{ github.actor }}
112119
113120
- name: Get & build for asset
114121
run: |
@@ -138,13 +145,13 @@ jobs:
138145
--file ci.Dockerfile .
139146
docker push ${{ env.IMAGE }}
140147
141-
# - name: Deploy to stacks
142-
# run: |
143-
# git clone git@github.com:coingaming/${{ inputs.stacks-repo }}
144-
# cd ${{ inputs.stacks-repo }}
145-
# git checkout ${{ inputs.stacks-branch-name }}
148+
- name: Deploy to stacks
149+
run: |
150+
git clone https://${{secrets.GH_TOKEN }}@github.com/${{ inputs.stacks-repo }}.git stacks
151+
cd stacks
152+
git checkout ${{ inputs.stacks-branch-name }}
146153
147-
# scripts/update-image ${{ inputs.stacks-name }} ${{inputs.service-name }} ${{ env.IMAGE }}
154+
scripts/update-image ${{ inputs.stacks-name }} ${{inputs.service-name }} ${{ env.IMAGE }}
148155
149-
# git commit -am "upgraded ${{inputs.service-name }} service with ${{ env.IMMAGE }}"
150-
# git push origin refs/heads/${{ inputs.stacks-branch-name }}:refs/heads/${{ inputs.stacks-branch-name }}
156+
git commit -am "upgraded ${{inputs.service-name }} service with ${{ env.IMAGE }}"
157+
git push origin refs/heads/${{ inputs.stacks-branch-name }}:refs/heads/${{ inputs.stacks-branch-name }}

0 commit comments

Comments
 (0)