Podman Compose
Start Kestra with a Postgres database backend using Podman Compose.
Before you begin
Make sure you have already installed:
Download the Docker Compose file
Download the Docker Compose file using the following command:
curl -o docker-compose.yml \
https://raw.githubusercontent.com/kestra-io/kestra/develop/docker-compose.yml
If you don't have curl
installed, you can download the Docker Compose file manually and save it as docker-compose.yml
.
Podman Compose will work using the provided Docker Compose file out of the box.
Launch Kestra
Use the following command to create a Podman machine, start it up and launch Kestra on it:
podman machine init --cpus 2 --rootful -v /tmp:/tmp -v $PWD:$PWD
podman machine start
podman compose up -d
Podman executes containers through a VM on your local machine. In order to access local volumes from your container you need to ensure you mount these to the podman VM, hence the -v /tmp:/tmp -v $PWD:$PWD
arguments.
Note: Check if you have an existing podman VM on your local machine by navigating to the 'Resources' tab in podman desktop or running the command podman machine list
in your terminal. If you have an existing VM, ensure the required volumes are mounted as expected. If that does not work, you can recreate the podman VM with volumes mounted and then run Kestra.
Open the URL http://localhost:8080
in your browser to launch the UI.
Adjusting the Configuration
The command above starts a standalone server (all architecture components in one JVM).
The configuration will be done inside the KESTRA_CONFIGURATION
environment variable of the Kestra container. You can update the environment variable inside the Docker compose file, or pass it via the Docker command line argument.
If you want to extend your Docker Compose file, modify container networking, or if you have any other issues using this Docker Compose file, check the Troubleshooting Guide.
Use a configuration file
If you want to use a configuration file instead of the KESTRA_CONFIGURATION
environment variable to configure Kestra you can update the default docker-compose.yml
.
First, create a configuration file, for example named application.yaml
and put inside the content of the KESTRA_CONFIGURATION
environment variable defined in the docker-compose.yml
file.
Then update kestra
servce in the docker-compose.yml
file to mount this file into the container and make Kestra using it via the --config
option:
# [...]
kestra:
image: kestra/kestra:latest-full
pull_policy: always
# Note that this is meant for development only. Refer to the documentation for production deployments of Kestra which runs without a root user.
user: "root"
command: server standalone --worker-thread=128 --config /etc/config/application.yaml
volumes:
- kestra-data:/app/storage
- /var/run/docker.sock:/var/run/docker.sock
- /tmp/kestra-wd:/tmp/kestra-wd
- $PWD/application.yaml:/etc/config/application.yaml
ports:
- "8080:8080"
- "8081:8081"
depends_on:
postgres:
condition: service_started
Was this page helpful?