@@ -1286,7 +1286,7 @@ async def container_to_args(
12861286 if isinstance (healthcheck_test , str ):
12871287 # podman does not add shell to handle command with whitespace
12881288 podman_args .extend ([
1289- "--healthcheck-command " ,
1289+ "--health-cmd " ,
12901290 json .dumps (["CMD-SHELL" , healthcheck_test ]),
12911291 ])
12921292 elif is_list (healthcheck_test ):
@@ -1296,11 +1296,11 @@ async def container_to_args(
12961296 if healthcheck_type == "NONE" :
12971297 podman_args .append ("--no-healthcheck" )
12981298 elif healthcheck_type == "CMD" :
1299- podman_args .extend (["--healthcheck-command " , json .dumps (healthcheck_test )])
1299+ podman_args .extend (["--health-cmd " , json .dumps (healthcheck_test )])
13001300 elif healthcheck_type == "CMD-SHELL" :
13011301 if len (healthcheck_test ) != 1 :
13021302 raise ValueError ("'CMD_SHELL' takes a single string after it" )
1303- podman_args .extend (["--healthcheck-command " , json .dumps (healthcheck_test )])
1303+ podman_args .extend (["--health-cmd " , json .dumps (healthcheck_test )])
13041304 else :
13051305 raise ValueError (
13061306 f"unknown healthcheck test type [{ healthcheck_type } ],\
@@ -1311,15 +1311,15 @@ async def container_to_args(
13111311
13121312 # interval, timeout and start_period are specified as durations.
13131313 if "interval" in healthcheck :
1314- podman_args .extend (["--healthcheck -interval" , healthcheck ["interval" ]])
1314+ podman_args .extend (["--health -interval" , healthcheck ["interval" ]])
13151315 if "timeout" in healthcheck :
1316- podman_args .extend (["--healthcheck -timeout" , healthcheck ["timeout" ]])
1316+ podman_args .extend (["--health -timeout" , healthcheck ["timeout" ]])
13171317 if "start_period" in healthcheck :
1318- podman_args .extend (["--healthcheck -start-period" , healthcheck ["start_period" ]])
1318+ podman_args .extend (["--health -start-period" , healthcheck ["start_period" ]])
13191319
13201320 # convert other parameters to string
13211321 if "retries" in healthcheck :
1322- podman_args .extend (["--healthcheck -retries" , str (healthcheck ["retries" ])])
1322+ podman_args .extend (["--health -retries" , str (healthcheck ["retries" ])])
13231323
13241324 # handle podman extension
13251325 if 'x-podman' in cnt :
0 commit comments