File tree 3 files changed +16
-7
lines changed
3 files changed +16
-7
lines changed Original file line number Diff line number Diff line change @@ -22,15 +22,22 @@ jobs:
22
22
- name : Fetch sanitized backup
23
23
run : |
24
24
s3cmd get s3://${{ vars.S3_BUCKET }}/latest.sanitized publisher/sanitized/latest.sanitized
25
+ s3cmd get s3://${{ vars.S3_BUCKET }}/plyo-db/latest_roles.out publisher/sanitized/latest_roles.out
26
+ - name : Set up Docker Buildx
27
+ uses : docker/setup-buildx-action@v2
28
+ with :
29
+ platforms : " linux/amd64,linux/arm64"
25
30
- name : Login to registry
26
31
uses : docker/login-action@v2
27
32
with :
28
33
registry : ${{ vars.REGISTRY }}
29
34
username : ${{ secrets.REGISTRY_USER }}
30
35
password : ${{ secrets.REGISTRY_PASS }}
31
- - name : Build DB image
32
- run : |
33
- image="${{ vars.REGISTRY }}/db:data"
34
- docker build -t ${image} -f ./publisher/Dockerfile ./publisher
35
- docker push ${image}
36
-
36
+ - name : Build and push docker image
37
+ uses : docker/build-push-action@v3
38
+ with :
39
+ context : ./publisher
40
+ platforms : " linux/amd64,linux/arm64"
41
+ push : true
42
+ tags : ' ${{ vars.REGISTRY }}/db:data'
43
+
Original file line number Diff line number Diff line change 1
- FROM plyo/postgres:database-7.3.0-14 .1
1
+ FROM plyo/postgres:database-7.3.0-13 .1
2
2
3
3
COPY ./sanitized/latest.sanitized /dumps/db.backup
4
+ COPY ./sanitized/latest_roles.out /dumps/roles.backup
4
5
COPY ./restore.sh /docker-entrypoint-initdb.d/
Original file line number Diff line number Diff line change
1
+ psql -f /dumps/roles.backup -U postgres
1
2
pg_restore /dumps/db.backup -U postgres -d ${DB_NAME}
You can’t perform that action at this time.
0 commit comments