'\" t .\" Title: ocf_heartbeat_podman .\" Author: ClusterLabs contributors (see the resource agent source for information about individual authors) .\" Generator: DocBook XSL Stylesheets vsnapshot .\" Date: 04/13/2023 .\" Manual: OCF resource agents .\" Source: resource-agents 4.12.0-2 .\" Language: English .\" .TH "OCF_HEARTBEAT_PODMAN" "7" "04/13/2023" "resource-agents 4.12.0-2" "OCF resource agents" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" ocf_heartbeat_podman \- Podman container resource agent\&. .SH "SYNOPSIS" .HP \w'\fBpodman\fR\ 'u \fBpodman\fR [start | stop | monitor | meta\-data | validate\-all] .SH "DESCRIPTION" .PP The podman HA resource agent creates and launches a podman container based off a supplied podman image\&. Containers managed by this agent are both created and removed upon the agent\*(Aqs start and stop actions\&. .SH "SUPPORTED PARAMETERS" .PP \fBimage\fR .RS 4 The podman image to base this container off of\&. .sp (required, string, no default) .RE .PP \fBname\fR .RS 4 The name to give the created container\&. By default this will be that resource\*(Aqs instance name\&. .sp (optional, string, no default) .RE .PP \fBallow_pull\fR .RS 4 Allow the image to be pulled from the configured podman registry when the image does not exist locally\&. NOTE, this can drastically increase the time required to start the container if the image repository is pulled over the network\&. .sp (optional, boolean, no default) .RE .PP \fBrun_opts\fR .RS 4 Add options to be appended to the \*(Aqpodman run\*(Aq command which is used when creating the container during the start action\&. This option allows users to do things such as setting a custom entry point and injecting environment variables into the newly created container\&. Note the \*(Aq\-d\*(Aq option is supplied regardless of this value to force containers to run in the background\&. .sp NOTE: Do not explicitly specify the \-\-name argument in the run_opts\&. This agent will set \-\-name using either the resource\*(Aqs instance or the name provided in the \*(Aqname\*(Aq argument of this agent\&. .sp (optional, string, no default) .RE .PP \fBrun_cmd\fR .RS 4 Specify a command to launch within the container once it has initialized\&. .sp (optional, string, no default) .RE .PP \fBmount_points\fR .RS 4 A comma separated list of directories that the container is expecting to use\&. The agent will ensure they exist by running \*(Aqmkdir \-p\*(Aq .sp (optional, string, no default) .RE .PP \fBmonitor_cmd\fR .RS 4 Specify the full path of a command to launch within the container to check the health of the container\&. This command must return 0 to indicate that the container is healthy\&. A non\-zero return code will indicate that the container has failed and should be recovered\&. .sp Note: Using this method for monitoring processes inside a container is not recommended, as containerd tries to track processes running inside the container and does not deal well with many short\-lived processes being spawned\&. Ensure that your container monitors its own processes and terminates on fatal error rather than invoking a command from the outside\&. .sp (optional, string, no default) .RE .PP \fBforce_kill\fR .RS 4 Kill a container immediately rather than waiting for it to gracefully shutdown .sp (optional, boolean, no default) .RE .PP \fBreuse\fR .RS 4 Allow the container to be reused once it is stopped\&. By default, containers get removed once they are stopped\&. Enable this option to have the particular one persist when this happens\&. .sp (optional, boolean, default 0) .RE .PP \fBdrop_in_dependency\fR .RS 4 Use transient drop\-in files to add extra dependencies to the systemd scopes associated to the container\&. During reboot, this prevents systemd to stop the container before pacemaker\&. .sp (optional, boolean, no default) .RE .SH "SUPPORTED ACTIONS" .PP This resource agent supports the following actions (operations): .PP \fBstart\fR .RS 4 Starts the resource\&. Suggested minimum timeout: 90s\&. .RE .PP \fBstop\fR .RS 4 Stops the resource\&. Suggested minimum timeout: 90s\&. .RE .PP \fBmonitor\fR .RS 4 Performs a detailed status check\&. Suggested minimum timeout: 30s\&. Suggested interval: 30s\&. .RE .PP \fBmeta\-data\fR .RS 4 Retrieves resource agent metadata (internal use only)\&. Suggested minimum timeout: 5s\&. .RE .PP \fBvalidate\-all\fR .RS 4 Performs a validation of the resource configuration\&. Suggested minimum timeout: 30s\&. .RE .SH "EXAMPLE CRM SHELL" .PP The following is an example configuration for a podman resource using the \fBcrm\fR(8) shell: .sp .if n \{\ .RS 4 .\} .nf primitive p_podman ocf:heartbeat:podman \e params \e image=\fIstring\fR \e op monitor timeout="30s" interval="30s" depth="0" .fi .if n \{\ .RE .\} .SH "EXAMPLE PCS" .PP The following is an example configuration for a podman resource using \fBpcs\fR(8) .sp .if n \{\ .RS 4 .\} .nf pcs resource create p_podman ocf:heartbeat:podman \e image=\fIstring\fR \e op monitor timeout="30s" interval="30s" OCF_CHECK_LEVEL="0" .fi .if n \{\ .RE .\} .SH "SEE ALSO" .PP \m[blue]\fB\%http://clusterlabs.org/\fR\m[] .SH "AUTHOR" .PP \fBClusterLabs contributors (see the resource agent source for information about individual authors)\fR