The official Docker image for Automad including Nginx and PHP.
In order to build this image with a specific version, run the following command:
docker build --build-arg version=v2.x-dev -t automad/automad:v2.x-dev .You can create a container called mysite and start it by using the following command:
docker run -dp 80:80 -v ./app:/app -e UID=$(id -u) --name mysite automad/automadThis will essentially make your site available at port 80 and mount a directory called /app for data persistence. The mount point will have the same UID assigned that is used by you on the host machine. This way permissions should work out of the box. A new user account for the Automad dashboard will be created automatically. The account details will be logged by the running container. You can show these logs using the following command:
docker logs mysiteYour can now navigate to localhost to view your new site.
Alternatively you can also use docker compose with the following configuration:
version: "3"
services:
  app:
    container_name: automad
    image: automad/automad:latest
    environment:
      UID: 1000 # your host UID
    ports:
      - 80:80
    volumes:
      - ./app:/appAnd then in order to start the container:
docker compose up -d