Quadlet: Difference between revisions
From wikinotes
No edit summary |
No edit summary |
||
Line 30: | Line 30: | ||
|} | |} | ||
</blockquote><!-- Locations --> | </blockquote><!-- Locations --> | ||
= Usage = | |||
<blockquote> | |||
While quadlet is technically an executable, it's designed to work with systemd commands directly. | |||
After adding your files to <code>~/.config/containers/systemd/*.{kube,container,volume,network,yml}</code>,<br> | |||
you can run daemon-reload and your generated systemd services will be made available. | |||
Here's the TL;DR from the official tutorial: | |||
<syntaxhighlight lang="bash"> | |||
mkdir -p $HOME/.config/containers/systemd/ | |||
cp envoy-proxy-configmap.yml \ | |||
quadlet-demo.kube \ | |||
quadlet-demo-mysql.container \ | |||
quadlet-demo-mysql.volume \ | |||
quadlet-demo.network \ | |||
quadlet-demo.yml \ | |||
$HOME/.config/containers/systemd/ | |||
systemctl --user daemon-reload | |||
systemctl --user start quadlet-demo.service | |||
</syntaxhighlight> | |||
</blockquote><!-- Usage --> |
Revision as of 18:26, 5 May 2024
Quadlet is a tool for generating systemd services from podman containers.
You can also describe a project as a podman-compose project, and generate systemd services for it as well.
The goal for the project is to be concise and change tolerant with sane defaults.
Documentation
src https://github.com/containers/podman/tree/main/pkg/systemd/quadlet
Tutorials
https://mo8it.com/blog/quadlet/ intro
Locations
~/.config/containers/systemd/*.container
build systemd services from these
Usage
While quadlet is technically an executable, it's designed to work with systemd commands directly.
After adding your files to
~/.config/containers/systemd/*.{kube,container,volume,network,yml}
,
you can run daemon-reload and your generated systemd services will be made available.Here's the TL;DR from the official tutorial:
mkdir -p $HOME/.config/containers/systemd/ cp envoy-proxy-configmap.yml \ quadlet-demo.kube \ quadlet-demo-mysql.container \ quadlet-demo-mysql.volume \ quadlet-demo.network \ quadlet-demo.yml \ $HOME/.config/containers/systemd/ systemctl --user daemon-reload systemctl --user start quadlet-demo.service