mirror of
https://github.com/Balshgit/python-poetry.git
synced 2026-02-03 11:20:40 +03:00
add files check to Dockerfile
This commit is contained in:
@@ -48,6 +48,11 @@ RUN export PATH="${PATH}:/root/.local/bin" \
|
||||
&& poetry lock \
|
||||
&& poetry export -f requirements.txt --with dev --without-hashes --output requirements.txt
|
||||
|
||||
RUN if [ -f poetry.lock ] && [ -f requirements.txt ]; then \
|
||||
echo "poetry.lock and requirements.txt created successfully" && exit 0; \
|
||||
else echo "there is no poetry.lock or requirements.txt" && exit 1; \
|
||||
fi
|
||||
|
||||
CMD [ "/bin/bash", "-c", "cp /code/* /poetry -r && chown ${USER}:$USER -R /poetry" ]
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user