Merge pull request #544 from jhollowe-forks/devcontainer

Add devcontainer configuration
pull/556/head
Jason Fischer 2 years ago committed by GitHub
commit 894d3ae0cb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -0,0 +1,6 @@
ARG VARIANT="16-buster"
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:${VARIANT}
RUN npm install -g pnpm
ENV PATH="${PATH}:./node_modules/.bin"

@ -0,0 +1,27 @@
{
"name": "homepage",
"build": {
"dockerfile": "Dockerfile",
"args": {
"VARIANT": "18-buster"
}
},
"customizations": {
"vscode": {
"extensions": [
"dbaeumer.vscode-eslint",
"mhutchie.git-graph",
"streetsidesoftware.code-spell-checker",
],
"settings": {
"eslint.format.enable": true,
"eslint.lintTask.enable": true,
"eslint.packageManager": "pnpm"
}
}
},
"postCreateCommand": ".devcontainer/setup.sh",
"forwardPorts": [
3000
]
}

@ -0,0 +1,11 @@
#!/usr/bin/env bash
# Install Node packages
pnpm install
# Copy in skeleton configuration if there is no existing configuration
if [ ! -d "config/" ]; then
echo "Adding skeleton config"
mkdir config/
cp -r src/skeleton/* config
fi
Loading…
Cancel
Save