Configurable Kamal directory
To avoid polluting the default SSH directory with lots of Kamal config, we'll default to putting them in a `kamal` sub directory. But also make the directory configurable with the `run_directory` key, so for example you can set it as `/var/run/kamal/` The directory is created during bootstrap or before any command that will need to access a file.
This commit is contained in:
@@ -283,4 +283,12 @@ class ConfigurationTest < ActiveSupport::TestCase
|
||||
Kamal::Configuration.new(@deploy.tap { |c| c.merge!(minimum_version: "10000.0.0") })
|
||||
end
|
||||
end
|
||||
|
||||
test "run directory" do
|
||||
config = Kamal::Configuration.new(@deploy)
|
||||
assert_equal "kamal", config.run_directory
|
||||
|
||||
config = Kamal::Configuration.new(@deploy.merge!(run_directory: "/root/kamal"))
|
||||
assert_equal "/root/kamal", config.run_directory
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user