From 76743ac1c6ca935244c4242b8b44f6738a2bcc03 Mon Sep 17 00:00:00 2001 From: Louise de Beaufort Date: Tue, 20 Aug 2019 12:38:53 +0200 Subject: [PATCH] Add a Dockerfile and instructions to run with Docker --- Dockerfile | 12 ++++++++++++ README.md | 10 ++++++++++ 2 files changed, 22 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..922d95a --- /dev/null +++ b/Dockerfile @@ -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"] diff --git a/README.md b/README.md index 90bc89b..a52af9f 100644 --- a/README.md +++ b/README.md @@ -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 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