Fail kamal app exec without a CMD

This commit is contained in:
Michael Weiner
2025-02-07 20:13:18 -06:00
parent 6f29d4e78b
commit 91259720b2

View File

@@ -108,6 +108,10 @@ class Kamal::Cli::App < Kamal::Cli::Base
raise ArgumentError, "Detach is not compatible with #{incompatible_options.join(" or ")}"
end
if cmd.empty?
raise ArgumentError, "No command provided. You must specify a command to execute."
end
cmd = Kamal::Utils.join_commands(cmd)
env = options[:env]
detach = options[:detach]