File tree Expand file tree Collapse file tree 1 file changed +1
-22
lines changed Expand file tree Collapse file tree 1 file changed +1
-22
lines changed Original file line number Diff line number Diff line change @@ -127,24 +127,7 @@ jobs:
127127 echo "public_ip=$(terraform output -raw db_host)" >> $GITHUB_OUTPUT
128128 echo "api_url=$(terraform output -raw cloud_run_service_url)" >> $GITHUB_OUTPUT
129129
130- - name : Check if tickets table exists
131- id : check_table
132- env :
133- PGPASSWORD : ${{ secrets.DB_PASSWORD }}
134- run : |
135- # install postgres client
136- sudo apt-get update && sudo apt-get install -y postgresql-client
137-
138- TABLE_EXISTS=$(psql -h ${{ steps.db.outputs.public_ip }} \
139- -U ${{ secrets.DB_USER }} \
140- -d ${{ secrets.DB_NAME }} \
141- -tAc "SELECT EXISTS (SELECT FROM pg_tables WHERE tablename = 'tickets');" \
142- )
143-
144- echo "table_exist=$TABLE_EXISTS" >> $GITHUB_OUTPUT
145-
146- - name : Create tables and populate (tickets table not existent)
147- if : steps.check_table.outputs.table_exist == 'f'
130+ - name : Populate table with test records
148131 env :
149132 PGPASSWORD : ${{ secrets.DB_PASSWORD }}
150133 run : |
@@ -159,10 +142,6 @@ jobs:
159142 -v DB_NAME=${{ secrets.DB_NAME }} \
160143 -v ON_ERROR_STOP=1
161144 done
162-
163- - name : Skipped table creation (existent tickets table)
164- if : steps.check_table.outputs.table_exist == 't'
165- run : echo ""
166145
167146 run-integration-tests :
168147 needs : deploy
You can’t perform that action at this time.
0 commit comments