feat: remove --restart docker arguments when not running deploy-phase containers

This works around cases where developers may inadvertently add this to `run` containers which _should not_ have the `--restart` flag. Run containers are one-off, and if they fail, then they should fail hard.
This commit is contained in:
Jose Diaz-Gonzalez committed 2024-08-25 23:33:49 -04:00
1 parent c5ac13977f
commit 12648e0bc6
1 file changed
+8
@@ -37,6 +37,14 @@ trigger-docker-options-docker-args() {
\#*) \#*)
continue continue
;; ;;
--restart*)
if [[ "$PHASE" == "deploy" ]]; then
local output="$output $line"
fi
continue
;;
*) *)
case "$IMAGE_SOURCE_TYPE" in case "$IMAGE_SOURCE_TYPE" in
dockerfile | nixpacks) dockerfile | nixpacks)