-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
22 lines (14 loc) · 720 Bytes
/
Dockerfile
File metadata and controls
22 lines (14 loc) · 720 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
FROM python:3.9-buster
RUN useradd -ms /bin/bash user
WORKDIR /root
RUN wget https://raw.githubusercontent.com/swagger-api/swagger-codegen/4607a90d7b69463a0ae8fc94fac68fc95d80965e/modules/swagger-codegen/src/main/resources/python/requirements.mustache -O requirements.txt && \
echo "argcomplete >= 1.10.0" >> requirements.txt && \
pip install -r requirements.txt && rm -f requirements.txt && \
mkdir /home/user/.bash_completion.d && \
activate-global-python-argcomplete --dest=/home/user/.bash_completion.d/ && \
echo "source ~/.bash_completion.d/python-argcomplete" >> /home/user/.bashrc
USER user
WORKDIR /app
ENV PYTHONPATH=/app
ADD openapi-cli.py /usr/local/bin/.
ENTRYPOINT ["/bin/bash"]