Skip to content
This repository was archived by the owner on Nov 30, 2023. It is now read-only.

Commit 284c16d

Browse files
committed
Moved pylint install into requirements.txt
1 parent 0c33d93 commit 284c16d

File tree

8 files changed

+18
-15
lines changed

8 files changed

+18
-15
lines changed

containers/python-3-django/.devcontainer/Dockerfile

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,12 @@ COPY .devcontainer/settings.vscode.json /root/.vscode-remote/data/User/settings.
1010

1111
ENV PYTHONUNBUFFERED 1
1212

13-
RUN pip install pylint
13+
RUN mkdir /workspace
14+
WORKDIR /workspace
1415

15-
RUN mkdir /app
16-
WORKDIR /app
17-
18-
COPY .devcontainer/requirements.txt /app/
19-
RUN pip install -r requirements.txt
16+
# Install pylint and Django
17+
COPY .devcontainer/requirements.txt /workspace/
18+
RUN pip install -r requirements.txt && rm -f requirements.txt
2019

2120
# Install git
2221
RUN apt-get update && apt-get -y install git
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1+
pylint
12
Django
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Django

containers/python-3-flask-redis/.devcontainer/Dockerfile

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,12 @@ FROM python:3-slim
88
# Copy default endpoint specific user settings overrides into container to specify Python path
99
COPY settings.vscode.json /root/.vscode-remote/data/User/settings.json
1010

11-
RUN mkdir /app
12-
WORKDIR /app
11+
RUN mkdir /workspace
12+
WORKDIR /workspace
1313

14-
COPY requirements.txt /app/
15-
RUN pip install -r requirements.txt
16-
17-
RUN pip install pylint
14+
# Install pylint, flask, redis
15+
COPY requirements.txt /workspace/
16+
RUN pip install -r requirements.txt && rm -f requirements.txt
1817

1918
# Install git
2019
RUN apt-get update && apt-get -y install git

containers/python-3-flask-redis/.devcontainer/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ services:
1212
ports:
1313
- "5000:5000"
1414
volumes:
15-
- ..:/app
15+
- ..:/workspace
1616
command: sleep infinity
1717
redis:
1818
image: "redis:alpine"
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1+
pylint
12
flask
2-
redis
3+
redis

containers/python-3-flask-redis/.vscode/devContainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "Python & Redis",
33
"dockerComposeFile": ".devcontainer/docker-compose.yml",
44
"service": "web",
5-
"volume": "app",
5+
"volume": "workspace",
66
"extensions": [
77
"ms-python.python",
88
"LittleFoxTeam.vscode-python-test-adapter"
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
flask
2+
redis

0 commit comments

Comments
 (0)