Skip to content

Commit 3809d5b

Browse files
authored
Update publish_new_release.yaml
1 parent a1e51d6 commit 3809d5b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

.github/workflows/publish_new_release.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,6 @@ jobs:
3939
git -C $HOME clone --single-branch --no-tags --depth=1 https://${{ secrets.LIBRESCORE_USERNAME }}:${{ secrets.LIBRESCORE_TOKEN }}@github.com/LibreScore/${{ secrets.LIBRESCORE_REPO_A }}
4040
cd $HOME/${{ secrets.LIBRESCORE_REPO_A }}
4141
sed -ri 's/"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.+"/echo \\ \\ \\ \\ \\ \\ \\"'"$jwt"'\\"\\;/e' lib/utils/db_api.dart
42-
cat lib/utils/db_api.dart
43-
git status
4442
4543
git config user.name github-actions
4644
git config user.email github-actions@github.com
@@ -49,7 +47,8 @@ jobs:
4947
git push --atomic origin master
5048
5149
echo "${{ secrets.SSH_KEY }}" | base64 --decode > $HOME/id_rsa
52-
ssh -i $HOME/id_rsa ${{ secrets.SSH_USERNAME }}@${{ secrets.SSH_DOMAIN }} 'sudo -u postgres psql librescore -c "create or replace function auth.check_token() returns void language plpgsql as \$\$ begin if current_setting('"'request.jwt.claims', true)::json->>'version' not in ('server', '${{ steps.get-latest-release.outputs.CURRENT_VERSION }}', '${{ steps.get-latest-release.outputs.LATEST_VERSION }}') then raise insufficient_privilege using hint = 'Outdated version'"'; end if; end \$\$;"'
50+
chmod 600 $HOME/id_rsa
51+
ssh -i $HOME/id_rsa -o StrictHostKeyChecking=accept-new ${{ secrets.SSH_USERNAME }}@${{ secrets.SSH_DOMAIN }} -p ${{ secrets.SSH_PORT }} 'sudo -u postgres psql librescore -c "create or replace function auth.check_token() returns void language plpgsql as \$\$ begin if current_setting('"'request.jwt.claims', true)::json->>'version' not in ('server', '${{ steps.get-latest-release.outputs.CURRENT_VERSION }}', '${{ steps.get-latest-release.outputs.LATEST_VERSION }}') then raise insufficient_privilege using hint = 'Outdated version'"'; end if; end \$\$;"'
5352
- name: Upload assets
5453
if: env.updated == 'true'
5554
uses: softprops/action-gh-release@v1

0 commit comments

Comments
 (0)