Mentions légales du service

Skip to content
Snippets Groups Projects
Commit 86d15b4d authored by BIGAUD Nathan's avatar BIGAUD Nathan
Browse files

v0 of Dockerfiles

parent 30fa9892
No related branches found
No related tags found
1 merge request!46Draft: Docker deploy
FROM python:3.9-alpine
# Define workdir
WORKDIR /experiment
# Define dynamic args
ARG script=client.py
ARG data
# Copy script
COPY $script /experiment/client.py
COPY data /experiment/data
# Set up volume
VOLUME /experiment
## Set up venv
RUN python -m venv ~/.venvs/declearn \
&& source ~/.venvs/declearn/bin/activate
# Install declearn
RUN pip install declearn[all]
# Run script
CMD ["python", "client.py","/experiment/data"]
\ No newline at end of file
FROM python:3.9-alpine FROM python:3.9-alpine
# Define workdir
WORKDIR /app WORKDIR /experiment
# Define dynamic args
COPY requirements.txt requirements.txt ARG script=server.py
RUN pip3 install -r requirements.txt # Copy script
COPY $script /experiment/server.py
COPY . . # Set up volume
VOLUME /experiment
CMD ["python3", "-m" , "flask", "run", "--host=0.0.0.0"] ## Set up venv
RUN python -m venv ~/.venvs/declearn \
&& source ~/.venvs/declearn/bin/activate
# Install declearn
RUN pip install declearn[all]
# Run script
CMD ["python", "server.py"]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment