Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add dev container for vscode #1643

Merged
merged 3 commits into from
Nov 12, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
FROM mcr.microsoft.com/vscode/devcontainers/python:3.8
psankhe28 marked this conversation as resolved.
Show resolved Hide resolved

RUN apt-get update && apt-get install -y \
git \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*

WORKDIR /workspace

COPY . .

RUN pip install -r docs/pip-requirements.txt

ENV MKDOCS_PORT=8000

EXPOSE ${MKDOCS_PORT}

CMD ["mkdocs", "serve", "-a", "0.0.0.0:8000"]
21 changes: 21 additions & 0 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"name": "Caliper Development",
"context": "..",
"dockerFile": "Dockerfile",
"customizations": {
"vscode": {
"settings": {
"terminal.integrated.shell.linux": "/bin/bash",
"python.defaultInterpreterPath": "/usr/local/bin/python"
},
"extensions": [
"ms-python.python",
"esbenp.prettier-vscode",
"ms-azuretools.vscode-docker"
]
}
},
"postCreateCommand": "cd docs && pip install -r pip-requirements.txt && mkdocs build",
"remoteUser": "vscode",
"forwardPorts": [8000]
}
psankhe28 marked this conversation as resolved.
Show resolved Hide resolved
Loading