-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (22 loc) · 745 Bytes
/
Copy pathDockerfile
File metadata and controls
27 lines (22 loc) · 745 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
FROM rust:bullseye
RUN set -xe && \
apt-get update && \
apt-get install -y --no-install-recommends locales && \
rm -rf /var/lib/apt/lists/* && \
echo "en_US.UTF-8 UTF-8" > /etc/locale.gen && \
locale-gen
ENV LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_ALL=en_US.UTF-8
RUN set -xe && \
apt-get update && \
apt-get install -y --no-install-recommends libseccomp-dev && \
apt-get install -y --no-install-recommends protobuf-compiler && \
rm -rf /var/lib/apt/lists/*
RUN groupadd --gid 1000 hako \
&& useradd --uid 1000 --gid hako --shell /bin/bash --create-home hako
RUN set -xe && \
cargo install hakoniwa-code-runner
WORKDIR /opt/hcr
COPY . .
USER 1000:1000
EXPOSE 8080
CMD ["hakoniwa-code-runner", "start", "-c", "app.toml"]