Skip to content

Commit

Permalink
fix: Mark /tmp as a container volume (#1546)
Browse files Browse the repository at this point in the history
Explicitly mark `/tmp` and `/.cache` as volumes so that the directories
are automatically created within the container.

Ideally `/tmp` should be a `tmpfs` mount and `/.cache` should be a
persistent mount, especially when the `bundle` driver is in use.

Signed-off-by: Charith Ellawala <charith@cerbos.dev>
  • Loading branch information
charithe committed Apr 26, 2023
1 parent 9c12c4f commit 8f66068
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Dockerfile.cerbos
Expand Up @@ -4,7 +4,7 @@ RUN apk add -U --no-cache ca-certificates && update-ca-certificates
FROM scratch
EXPOSE 3592 3593
ENV CERBOS_CONFIG="__default__"
VOLUME ["/policies"]
VOLUME ["/policies", "/tmp", "/.cache"]
ENTRYPOINT ["/cerbos"]
CMD ["server"]
HEALTHCHECK --interval=1m --timeout=3s CMD ["/cerbos", "healthcheck"]
Expand Down

0 comments on commit 8f66068

Please sign in to comment.