Nathan Price
5caac7aead
Moved previous stages to base image. Removed unneeded Makefile targets. PDS_HOSTNAME must be the same as the container $hostname.
46 lines
No EOL
1.7 KiB
Docker
46 lines
No EOL
1.7 KiB
Docker
################################################################################
|
|
# adapted from https://github.com/bluesky-social/pds/blob/v0.4.74/installer.sh
|
|
################################################################################
|
|
FROM pds-runtime
|
|
|
|
ENV LOG_ENABLED="true"
|
|
ENV PDS_BLOB_UPLOAD_LIMIT="52428800"
|
|
ENV PDS_DATADIR="/pds"
|
|
ENV PDS_DATA_DIRECTORY="/pds"
|
|
ENV PDS_BLOBSTORE_DISK_LOCATION="${PDS_DATADIR}/blocks"
|
|
ENV PDS_DID_PLC_URL="https://plc.directory"
|
|
ENV PDS_BSKY_APP_VIEW_URL="https://api.bsky.app"
|
|
ENV PDS_BSKY_APP_VIEW_DID="did:web:api.bsky.app"
|
|
ENV PDS_REPORT_SERVICE_URL="https://mod.bsky.app"
|
|
ENV PDS_REPORT_SERVICE_DID="did:plc:ar7c4by46qjdydhdevvrndac"
|
|
ENV PDS_CRAWLERS="https://bsky.network"
|
|
|
|
RUN mv pdsadmin.sh /usr/local/bin/pdsadmin && \
|
|
chmod +x /usr/local/bin/pdsadmin && \
|
|
mkdir --mode=700 --parent ${PDS_DATADIR} && \
|
|
rm -rf pds-0.4.74 v0.4.74.zip && \
|
|
apt-get clean && \
|
|
rm -rf /var/lib/apt/lists/*
|
|
|
|
|
|
ENV PUID=1000
|
|
ENV PGID=1000
|
|
|
|
RUN groupadd --gid ${PGID} pds
|
|
RUN useradd --home=${PDS_DATADIR} --uid=${PUID} --no-user-group pds
|
|
RUN usermod --gid ${PGID} pds
|
|
RUN chown -R pds:pds ${PDS_DATADIR}
|
|
|
|
ENTRYPOINT ["dumb-init", "--"]
|
|
|
|
COPY entrypoint.sh /entrypoint.sh
|
|
RUN chmod +x /entrypoint.sh
|
|
|
|
CMD ["sh", "-c", "chown -R ${PUID}:${PGID} /pds && su pds && /entrypoint.sh"]
|
|
|
|
|
|
LABEL org.opencontainers.image.source="https://forgejo.gravityfargo.dev/gravityfargo/bluesky-pds-docker"
|
|
LABEL org.opencontainers.image.url="https://github.com/bluesky-social/pds"
|
|
LABEL org.opencontainers.image.description="A self contained PDS instance without caddy."
|
|
LABEL org.opencontainers.image.licenses="MIT"
|
|
LABEL org.opencontainers.image.authors="Nathan Price <nathan@gravityfargo.dev>" |