- 
                Notifications
    You must be signed in to change notification settings 
- Fork 636
Description
Context
Right now all kamal deployment related files stored in .kamal dir, except main deploy.yml config, which is stored in config/deploy.yml by default.
Some of us want to have all files related to kamal deployment in one dir .kamal.
Others also can have different locations for some reason.
We can specify config file via --config-file=CONFIG_FILE option on each kamal command invocation.
But it feels redundant and exhausting over time, especially with mostly manually invoking aliases-commands.
Taking into account that in most cases there will be one main deploy config, it would be nice to have this options saved on kamal init run and used automatically on other kamal commands.
Feature proposal
Feels like it can be achieved with minimal changes.
For example. There could be generated .kamal/options.yml or .kamal/defaults.yml file to save general/default options to use with all kamal future invocations.
We can read this config_file option from mentioned file and apply in the only place it is used (in file lib/kamal/cli/base.rb):
          commander.configure \
            config_file: Pathname.new(File.expand_path(options[:config_file])),Note: .kamal/options.yml should be suitable solution to eliminate issues and ours of recovery when forgetting to specify options. E.g. setting default destination as staging for safety.
@djmb Let me know your thoughts on this extension proposal. I can take care of implementation if it sounds interesting.