Update gcc g++ node go

This commit is contained in:
MeiK 2020-10-29 12:47:50 +08:00
parent bcf761bdc0
commit f346e88c38
2 changed files with 25 additions and 6 deletions

View File

@ -7,25 +7,45 @@ WORKDIR /river
RUN rustup component add rustfmt --toolchain 1.47.0-x86_64-unknown-linux-gnu && \
cargo build --release
FROM ubuntu:18.04
ENV LANG C.UTF-8
RUN apt update
# install gcc g++
RUN apt install -y \
g++ \
gcc \
libc6-dev \
make \
pkg-config
# install python3.6
RUN apt update && \
apt install -y software-properties-common && \
RUN apt install -y software-properties-common && \
add-apt-repository -y ppa:deadsnakes/ppa && \
apt install python3.6
# install rust
RUN apt install -y curl && \
curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y
ENV PATH=/root/.cargo/bin:$PATH
ENV PATH="/root/.cargo/bin:${PATH}"
# install node
RUN curl -sL https://deb.nodesource.com/setup_14.x | bash - && \
apt install -y nodejs
# install go
RUN add-apt-repository -y ppa:gophers/archive && \
apt install golang-go
# TODO: install other languages
COPY ./plugins /plugins
RUN rm -rf /var/lib/apt/lists/*
COPY ./plugins /plugins
ENV PATH="/plugins/js:${PATH}"
RUN /plugins/build.sh
WORKDIR /river

View File

@ -4,9 +4,8 @@ echo "Hello World!"
# create judge dir
mkdir -p /river/runner
# add to path
export PATH=$PATH:/plugins/js
cd /plugins/js
npm install
npm install -g ts-node typescript
echo "Hello World!"