Skip to content

Commit

Permalink
Use Arch Linux as docker image base
Browse files Browse the repository at this point in the history
  • Loading branch information
macie committed Mar 6, 2019
1 parent 1d3e3a2 commit 47170c1
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 5 deletions.
28 changes: 23 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,29 @@
FROM python:3-alpine
FROM archlinux/base

LABEL Name=boludo \
Version=0.0.1
EXPOSE 3001

WORKDIR /src
ADD . /src
# configure OS
ENV PATH /usr/local/bin:$PATH
ENV LANG C.UTF-8
RUN pacman -Sy

# python dependencies:
RUN python3 -m pip install -r requirements.txt
# prepare user
RUN useradd -m boludo
WORKDIR /home/boludo

# install OS packages
RUN pacman -S --noconfirm swi-prolog
RUN pacman -S --noconfirm python python-pip

# install python dependencies
COPY requirements.txt requirements.txt
RUN pip install -r requirements.txt

#COPY ./src src

RUN chown -R boludo:boludo ./
USER boludo

CMD [ "/bin/bash" ]
4 changes: 4 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,9 @@ services:
boludo:
image: boludo
build: .
stdin_open: true
tty: true
ports:
- 3001:3001
volumes:
- ./src:/home/boludo/app

0 comments on commit 47170c1

Please sign in to comment.