Skip to content

Commit

Permalink
fix: point to a real docker tag (#2)
Browse files Browse the repository at this point in the history
* fix: point to a real docker tag
* fix: ARG PG_TAG is not working for some reason
* fix: source link to repo
  • Loading branch information
bf4 authored Mar 23, 2023
1 parent 644d5e8 commit 0416939
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 9 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
regression.*
*.o
*.so
.github/*
5 changes: 3 additions & 2 deletions .github/workflows/build-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,6 @@ jobs:
tags: ghcr.io/x-b-e/server-pg:latest
build-args: |
PG_MAJOR=13
# outputs: type=image,name=target,annotation-index.org.opencontainers.image.description=XBE server base
# cache-from: ghcr.io/x-b-e/server-base
PG_TAG=13-13.3
# outputs: type=image,name=target,annotation-index.org.opencontainers.image.description=XBE server pg
# cache-from: ghcr.io/x-b-e/server-pg
16 changes: 9 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,28 +1,30 @@
# syntax=docker/dockerfile:1

ARG PG_MAJOR="13"
ARG PG_TAG="13-13.3"

FROM postgis/postgis:${PG_MAJOR}
FROM postgis/postgis:13-3.3
# FROM postgis/postgis:${PG_TAG}

LABEL org.opencontainers.image.source "https://github.com/x-b-e/server-pg"
LABEL org.opencontainers.image.source "https://github.com/x-b-e/pgvector"
LABEL org.opencontainers.image.description "XBE server postgres with postgis, pgvector"
LABEL org.opencontainers.image.licenses "PostgreSQL License"

ARG PG_MAJOR

ENV PG_MAJOR=${PG_MAJOR}
# ARG PG_MAJOR
# ENV PG_MAJOR=${PG_MAJOR}
ENV PG_MAJOR=13

COPY . /tmp/pgvector

RUN apt-get update && \
apt-get install -y --no-install-recommends build-essential postgresql-server-dev-${PGMAJOR} && \
apt-get install -y --no-install-recommends build-essential postgresql-server-dev-${PG_MAJOR} && \
cd /tmp/pgvector && \
make clean && \
make OPTFLAGS="" && \
make install && \
mkdir /usr/share/doc/pgvector && \
cp LICENSE README.md /usr/share/doc/pgvector && \
rm -r /tmp/pgvector && \
apt-get remove -y build-essential postgresql-server-dev-${PGMAJOR} && \
apt-get remove -y build-essential postgresql-server-dev-${PG_MAJOR} && \
apt-get autoremove -y && \
rm -rf /var/lib/apt/lists/*

0 comments on commit 0416939

Please sign in to comment.