source/projects/activitypub_relay/Dockerfile

26 lines
622 B
Docker
Raw Normal View History

2022-11-20 06:45:47 +00:00
FROM library/python:3.10
MAINTAINER Reid 'arrdem' McKenzie <me@arrdem.com>
2022-11-20 06:45:47 +00:00
RUN pip install --upgrade pip
RUN useradd -d /app app
RUN mkdir -p /app
2022-11-20 06:45:47 +00:00
RUN chown -R app:app /app
USER app
WORKDIR /app
VOLUME /data
ENV DOCKER_RUNNING=true
2022-11-20 06:45:47 +00:00
ENV PYTHONPATH="/app:${PYTHONPATH}"
ENV PATH="/app/.local/bin:${PATH}"
2022-11-20 06:45:47 +00:00
### App specific crap
# Deps vary least so do them first
2022-11-26 22:46:42 +00:00
RUN pip3 install --user install aiohttp aiohttp_basicauth async_lru cachetools click pycryptodome pyyaml retry
2022-11-20 06:45:47 +00:00
COPY --chown=app:app docker_relay.sh /app/relay.sh
COPY --chown=app:app src/python /app/
2022-11-20 06:45:47 +00:00
EXPOSE 8080
ENTRYPOINT ["/bin/sh", "/app/relay.sh"]