mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
w: add docker installation (#152)
This commit is contained in:
1 parent
715e564971
commit
7b75a961bc
7 files changed
+174
No files matched your search
@@ -0,0 +1,29 @@
|
||||
FROM node:14
|
||||
|
||||
ADD ./entrypoint.sh /root/entrypoint.sh
|
||||
ADD ./judge.yaml /root/judge.yaml
|
||||
|
||||
RUN yarn global add pm2 @hydrooj/hydrojudge && \
|
||||
wget https://s3.undefined.moe/file/executor-amd64 -O /usr/bin/sandbox && \
|
||||
chmod +x /usr/bin/sandbox
|
||||
|
||||
RUN apt-get -qq update && \
|
||||
apt-get install -y \
|
||||
gcc \
|
||||
python3 \
|
||||
g++ \
|
||||
fp-compiler \
|
||||
openjdk-8-jdk-headless \
|
||||
python \
|
||||
php7.0-cli \
|
||||
rustc \
|
||||
haskell-platform \
|
||||
libjavascriptcoregtk-4.0-bin \
|
||||
golang \
|
||||
ruby \
|
||||
mono-runtime \
|
||||
mono-mcs
|
||||
|
||||
RUN chmod +x /root/entrypoint.sh
|
||||
|
||||
ENTRYPOINT /root/entrypoint.sh
|
||||
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
|
||||
ROOT=/root/.config/hydro
|
||||
|
||||
mkdir -p $ROOT
|
||||
|
||||
if [ ! -f "$ROOT/judge.yaml" ]; then
|
||||
cp /root/judge.yaml $ROOT
|
||||
fi
|
||||
|
||||
pm2 start sandbox
|
||||
pm2-runtime start hydrojudge
|
||||
@@ -0,0 +1,7 @@
|
||||
hosts:
|
||||
localhost:
|
||||
type: hydro # vj4 用户请在此处填写 vj4
|
||||
server_url: http://oj-backend:8888/ # Hydro 运行的网址
|
||||
uname: root # 评测账号用户名
|
||||
password: rootroot # 评测账号密码
|
||||
detail: true # 默认为 true
|
||||
Reference in new issue
Block a user