Add a Dockerfile and instructions to run with Docker

This commit is contained in:
Louise de Beaufort 2019-08-20 12:38:53 +02:00
parent 47e2eb6556
commit 76743ac1c6
2 changed files with 22 additions and 0 deletions

12
Dockerfile Normal file
View file

@ -0,0 +1,12 @@
FROM python:3-alpine
WORKDIR /workdir
RUN apk add alpine-sdk autoconf automake libtool gcc
ADD relay /workdir/relay
ADD requirements.txt /workdir/
RUN pip3 install -r requirements.txt
ADD relay.yaml /workdir/
CMD ["python", "-m", "relay"]
VOLUME ["/workdir/data"]

View file

@ -69,3 +69,13 @@ This will show the available management tasks:
When following remote relays, you should use the `/actor` endpoint as you would in When following remote relays, you should use the `/actor` endpoint as you would in
Pleroma and other LitePub-compliant software. Pleroma and other LitePub-compliant software.
## Docker
You can run ActivityRelay with docker. Edit `relay.yaml` so that the database
location is set to `./data/relay.jsonld` and then build and run the docker
image :
$ docker volume create activityrelay-data
$ docker build -t activityrelay .
$ docker run -d -p 8080:8080 -v activityrelay-data:/workdir/data activityrelay