This commit is contained in:
@@ -2,6 +2,9 @@
|
||||
# Builder
|
||||
#
|
||||
|
||||
FROM scratch AS private
|
||||
ADD git@code.fizz.buzz:talexander/homepage_private.git /homepage_private
|
||||
|
||||
FROM nixos/nix:2.31.3 AS builder
|
||||
|
||||
RUN tee -a /etc/nix/nix.conf <<EOF
|
||||
@@ -15,7 +18,8 @@ RUN cp "$(nix build nixpkgs#cacert --print-out-paths)/etc/ssl/certs/ca-bundle.cr
|
||||
COPY . /tmp/build
|
||||
WORKDIR /tmp/build
|
||||
|
||||
RUN nix build '.#docker_env'
|
||||
COPY --link --from=private /homepage_private /private
|
||||
RUN nix build --override-input homepage_private /private '.#docker_env'
|
||||
|
||||
# Export the built closure to a folder
|
||||
RUN mkdir /tmp/nix-store-closure
|
||||
@@ -41,6 +45,7 @@ COPY --from=builder /tmp/ca-bundle.crt /etc/ssl/certs/ca-bundle.crt
|
||||
COPY --from=builder /tmp/nix-store-closure /nix/store
|
||||
COPY --from=builder /tmp/build/result /app
|
||||
COPY --from=builder /tmp/sh /bin/sh
|
||||
|
||||
EXPOSE 8080
|
||||
#RUN addgroup web && adduser -D -G web web
|
||||
#&& install -d -D -o web -g web -m 700 /srv/http/public
|
||||
|
||||
Reference in New Issue
Block a user