fleet/Dockerfile
CptOfEvilMinions f735317f07
Updated .dockerignore and added non-root user to Dockerfile (#143)
Running applications as root (default Docker user) is not a good security practice. The goal of this PR is to run the Fleet application as a non-root user. 

For development you can still access the container as root with the following command: `docker run -it --user=0 <fleetdm container ID> bash`
2020-12-22 08:23:17 -08:00

13 lines
310 B
Docker

FROM alpine
MAINTAINER Fleet Developers <engineering@fleetdm.com>
RUN apk --update add ca-certificates
# Create FleetDM group and user
RUN addgroup -S fleet && adduser -S fleet -G fleet
COPY ./build/binary-bundle/linux/fleet ./build/binary-bundle/linux/fleetctl /usr/bin/
USER fleet
CMD ["fleet", "serve"]