-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile.asteroid
More file actions
45 lines (33 loc) · 1.23 KB
/
Dockerfile.asteroid
File metadata and controls
45 lines (33 loc) · 1.23 KB
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
FROM debian:bookworm-slim AS builder
RUN apt-get update && \
apt-get install -y curl openssl ca-certificates \
git make sbcl rlwrap && \
rm -rf /var/lib/apt/lists/*
WORKDIR /app
# Copy asteroid source to container workdir
COPY . .
# Download Quicklisp installer
RUN curl -O https://beta.quicklisp.org/quicklisp.lisp
# Installs quicklisp and radiance
RUN sbcl --eval "(load \"quicklisp.lisp\")" \
--eval "(quicklisp-quickstart:install)" \
--eval "(ql-dist:install-dist \"http://dist.shirakumo.org/shirakumo.txt\" :prompt nil)" \
--eval "(ql:quickload :radiance)"
# Makes the project workdir known as a quicklisp project
RUN mkdir -p "$HOME/.config/common-lisp/source-registry.conf.d"
RUN echo '(:tree "/app/")' >> "$HOME/.config/common-lisp/source-registry.conf.d/projects.conf"
# Adds radiance system configuration file
RUN mkdir -p /root/.config/radiance/asteroid/radiance-core
COPY docker/radiance-default.conf.lisp /root/.config/radiance/asteroid/radiance-core/radiance-core.conf.lisp
# Builds Asteroid binary
ARG BUILD_FLAGS
ENV BUILD_FLAGS=${BUILD_FLAGS}
RUN make
# Links binary to path
ENV PATH="$PATH:/app"
# Application
EXPOSE 8080
# Slynk server
EXPOSE 4009
ENV ASTEROID_STREAM_URL=http://localhost:8000
CMD [ "asteroid" ]