Added support for SoapBox UI

This commit is contained in:
Hal Lesesne 2021-04-29 13:04:18 -04:00
parent dc000fefe4
commit c115c60cce
4 changed files with 14 additions and 1 deletions

View File

@ -40,10 +40,14 @@ RUN mkdir -p /etc/pleroma /var/lib/pleroma/static /var/lib/pleroma/uploads && \
adduser --system --shell /bin/false --home /opt/pleroma --group pleroma && \ adduser --system --shell /bin/false --home /opt/pleroma --group pleroma && \
chown -vR pleroma /etc/pleroma /var/lib/pleroma chown -vR pleroma /etc/pleroma /var/lib/pleroma
COPY --chown=pleroma:pleroma --from=unzip /opt/pleroma/ /opt/pleroma/ COPY --chown=pleroma:pleroma --from=unzip /opt/pleroma/ /opt/pleroma/
VOLUME [ "/etc/pleroma", "/var/lib/pleroma/uploads", "/var/lib/pleroma/static" ] VOLUME [ "/etc/pleroma", "/var/lib/pleroma/uploads", "/var/lib/pleroma/static" ]
ADD https://gitlab.com/soapbox-pub/soapbox-fe/-/jobs/artifacts/v1.2.3/download?job=build-production /tmp/soapbox-fe.zip
RUN chown pleroma /tmp/soapbox-fe.zip
USER pleroma USER pleroma
COPY *.sh /opt/pleroma/bin/ COPY *.sh /opt/pleroma/bin/

View File

@ -39,6 +39,8 @@ See the [documentation for `instance gen`](https://docs-develop.pleroma.social/b
If you want to use RUM indexes, you need a [PostgreSQL container that supports them](https://github.com/jordemort/docker-postgres-rum/). If you want to use RUM indexes, you need a [PostgreSQL container that supports them](https://github.com/jordemort/docker-postgres-rum/).
If you would like to use the [SoapBox UI](https://soapbox.pub/), you can set an environment variable USE_SOAPBOX to "y".
## Persistence ## Persistence
If you want your instance data to persist properly, you need to mount volumes on the following directories: If you want your instance data to persist properly, you need to mount volumes on the following directories:

View File

@ -1,3 +1,4 @@
version: '3.7'
services: services:
pleroma: pleroma:
@ -7,7 +8,7 @@ services:
networks: networks:
pleromanet: pleromanet:
ports: ports:
- 127.0.0.1:4000:4000 - 4000:4000
volumes: volumes:
- config:/etc/pleroma - config:/etc/pleroma
- uploads:/var/lib/pleroma/uploads - uploads:/var/lib/pleroma/uploads
@ -16,6 +17,7 @@ services:
DOMAIN: localhost DOMAIN: localhost
ADMIN_EMAIL: chicken@example.com ADMIN_EMAIL: chicken@example.com
USE_RUM: "y" USE_RUM: "y"
USE_SOAPBOX: "n"
POSTGRES_PASSWORD: hunter2 POSTGRES_PASSWORD: hunter2
postgres: postgres:

View File

@ -17,4 +17,9 @@ if [ "${USE_RUM:-n}" = "y" ] ; then
pleroma_ctl migrate --migrations-path priv/repo/optional_migrations/rum_indexing/ pleroma_ctl migrate --migrations-path priv/repo/optional_migrations/rum_indexing/
fi fi
if [ "${USE_SOAPBOX:-n}" = "y" ]; then
unzip -o /tmp/soapbox-fe.zip -d /var/lib/pleroma
rm /tmp/soapbox-fe.zip
fi
exec pleroma start exec pleroma start