mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
devcontainer: bump node version to 22 and update feature installation (#1017)
This commit is contained in:
1 parent
43114ccf86
commit
a3226f724f
3 files changed
+20
-12
No files matched your search
@@ -1,9 +1,5 @@
|
|||||||
FROM mcr.microsoft.com/vscode/devcontainers/typescript-node:20-bookworm
|
FROM mcr.microsoft.com/vscode/devcontainers/typescript-node:22-bookworm
|
||||||
ADD https://github.com/criyle/go-judge/releases/download/v1.8.0/go-judge_1.8.0_linux_amd64 /usr/bin/sandbox
|
|
||||||
RUN npm install -g yarn && \
|
RUN install -d -o root -g root /root/.hydro /data/file && \
|
||||||
sudo apt-get update && sudo apt-get install gcc g++ && \
|
|
||||||
mkdir -p /root/.hydro /data/file && chmod +x /usr/bin/sandbox && \
|
|
||||||
chown -R root:root /root /root/.hydro /data/file && \
|
|
||||||
echo '{"uri":"mongodb://mongo/hydro"}' > /root/.hydro/config.json && \
|
echo '{"uri":"mongodb://mongo/hydro"}' > /root/.hydro/config.json && \
|
||||||
echo '["@hydrooj/ui-default","@hydrooj/hydrojudge"]' > /root/.hydro/addon.json
|
echo '["@hydrooj/ui-default","@hydrooj/hydrojudge"]' > /root/.hydro/addon.json
|
||||||
ENTRYPOINT sandbox
|
|
||||||
@@ -9,8 +9,6 @@
|
|||||||
"dbaeumer.vscode-eslint",
|
"dbaeumer.vscode-eslint",
|
||||||
"gruntfuggly.todo-tree",
|
"gruntfuggly.todo-tree",
|
||||||
"ronnidc.nunjucks",
|
"ronnidc.nunjucks",
|
||||||
"eamodio.gitlens",
|
|
||||||
"vscode-icons-team.vscode-icons",
|
|
||||||
"sysoev.language-stylus"
|
"sysoev.language-stylus"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -20,5 +18,18 @@
|
|||||||
2333,
|
2333,
|
||||||
8000
|
8000
|
||||||
],
|
],
|
||||||
|
"features": {
|
||||||
|
"ghcr.io/devcontainers-extra/features/gh-release:1": {
|
||||||
|
"repo": "criyle/go-judge",
|
||||||
|
"binaryNames": "go-judge",
|
||||||
|
"assetRegex": "go-judge_.*\\.tar\\.gz"
|
||||||
|
},
|
||||||
|
"ghcr.io/devcontainers-extra/features/apt-packages:1": {
|
||||||
|
"packages": [
|
||||||
|
"gcc",
|
||||||
|
"g++"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
"postCreateCommand": "git submodule update --init && yarn install && npx hydrooj cli system set server.port 2333 && npx hydrooj cli user create root@hydro.local root rootroot 2 && npx hydrooj cli user setSuperAdmin 2"
|
"postCreateCommand": "git submodule update --init && yarn install && npx hydrooj cli system set server.port 2333 && npx hydrooj cli user create root@hydro.local root rootroot 2 && npx hydrooj cli user setSuperAdmin 2"
|
||||||
}
|
}
|
||||||
@@ -1,8 +1,6 @@
|
|||||||
version: '3.9'
|
|
||||||
|
|
||||||
services:
|
services:
|
||||||
mongo:
|
mongo:
|
||||||
image: mongo:4-focal
|
image: mongo:8
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
volumes:
|
volumes:
|
||||||
- mongodb-data:/data/db
|
- mongodb-data:/data/db
|
||||||
@@ -15,8 +13,11 @@ services:
|
|||||||
- mongo
|
- mongo
|
||||||
volumes:
|
volumes:
|
||||||
- ..:/workspace:cached
|
- ..:/workspace:cached
|
||||||
|
- node_modules:/workspace/node_modules
|
||||||
- testdata:/data/file
|
- testdata:/data/file
|
||||||
|
command: go-judge
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
mongodb-data:
|
mongodb-data:
|
||||||
|
node_modules:
|
||||||
testdata:
|
testdata:
|
||||||
Reference in new issue
Block a user