Skip to content
This repository has been archived by the owner on Oct 3, 2024. It is now read-only.

Commit

Permalink
[CI] Docker image build
Browse files Browse the repository at this point in the history
  • Loading branch information
automainint committed Jun 4, 2024
1 parent a1a967b commit c0b8180
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 14 additions & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,3 +39,17 @@ jobs:
run: |
export RUST_TEST_THREADS=1
cargo pgrx test --runas postgres --pgdata /var/lib/postgresql/pgrx
docker_build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build postgres docker image
run: |
docker build -t tentura_postgres:latest .
docker image save tentura_postgres:latest -o tentura_postgres_latest.tar
- name: Upload postgres docker image
uses: actions/upload-artifact@v4
with:
name: tentura_postgres_latest.tar
path: tentura_postgres_latest.tar
retention-days: 2
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ RUN cargo pgrx package
FROM postgis/postgis:16-3.4-alpine
COPY --from=compile /usr/project/target/release/pgmer2-pg16/usr/lib/postgresql16/pgmer2.so /usr/local/lib/postgresql/pgmer2.so
COPY --from=compile /usr/project/target/release/pgmer2-pg16/usr/share/postgresql16/extension/pgmer2.control /usr/local/share/postgresql/extension/pgmer2.control
COPY --from=compile /usr/project/target/release/pgmer2-pg16/usr/share/postgresql16/extension/pgmer2--0.3.1.sql /usr/local/share/postgresql/extension/pgmer2--0.3.1.sql
COPY --from=compile /usr/project/target/release/pgmer2-pg16/usr/share/postgresql16/extension/pgmer2--0.3.2.sql /usr/local/share/postgresql/extension/pgmer2--0.3.2.sql
COPY 20_pgmer2.sh /docker-entrypoint-initdb.d/20_pgmer2.sh
# ENV POSTGRES_PASSWORD=1
ENV POSTGRES_HOST_AUTH_METHOD=trust
Expand Down

0 comments on commit c0b8180

Please sign in to comment.