Skip to content

Commit f9fb64b

Browse files
authored
dev: sync devcontainer
1 parent c8f36d9 commit f9fb64b

3 files changed

Lines changed: 29 additions & 30 deletions

File tree

.devcontainer/Dockerfile

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
FROM mcr.microsoft.com/devcontainers/python:3.12
2+
3+
# Install GitHub CLI
4+
RUN rm -f /etc/apt/sources.list.d/yarn*.list || true && \
5+
rm -f /etc/apt/trusted.gpg.d/yarn*.gpg || true && \
6+
curl -fsSL https://cli.github.com/packages/githubcli-archive-keyring.gpg | dd of=/usr/share/keyrings/githubcli-archive-keyring.gpg && \
7+
echo "deb [signed-by=/usr/share/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | tee /etc/apt/sources.list.d/github-cli.list && \
8+
apt-get update && \
9+
apt-get install -y gh && \
10+
apt-get clean && rm -rf /var/lib/apt/lists/*
11+
12+
# Install Railway CLI
13+
RUN curl -fsSL https://railway.app/install.sh | bash
14+
15+
# Configure Git
16+
RUN git config --global pull.ff true
17+
18+
# Install Poetry
19+
RUN pip install poetry && \
20+
poetry config virtualenvs.in-project true && \
21+
poetry config virtualenvs.create true
22+
23+
# Install poetry-shell plugin
24+
RUN poetry self add poetry-plugin-shell

.devcontainer/devcontainer.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
{
22
"name": "Python Flask DevContainer",
3-
"image": "mcr.microsoft.com/devcontainers/python:3.12",
3+
"build": {
4+
"dockerfile": "Dockerfile"
5+
},
46
"customizations": {
57
"vscode": {
68
"settings": {
@@ -12,6 +14,6 @@
1214
]
1315
}
1416
},
15-
"postCreateCommand": "bash .devcontainer/post-create.sh",
17+
"postCreateCommand": "poetry install --no-root",
1618
"remoteUser": "vscode"
17-
}
19+
}

.devcontainer/post-create.sh

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)