Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Customize init command with optional arguments #658

Open
hschne opened this issue Jan 23, 2024 · 3 comments
Open

Customize init command with optional arguments #658

hschne opened this issue Jan 23, 2024 · 3 comments

Comments

@hschne
Copy link

hschne commented Jan 23, 2024

When running kamal init a deploy.yml file with hard-coded values for repository, user, etc. is created. Users have to modify this file to suit their needs manually.

service: my-app # <<<

image: user/my-app # <<<

servers:
  - 192.168.0.1 # <<<

registry:
  username: my-user # <<<

Proposition

These hard-coded values could either be inferred from the environment (e.g. username, directory...) or at least be customizable in the kamal init command. For example:

kamal init --service app-name --user user-name --server 192.168.0.1

I'd be happy to work on this. What do you think?

@acidtib
Copy link
Contributor

acidtib commented Jan 26, 2024

I like that kamal init creates a .yml file for me to manually modify to my needs, not every kamal deployment is the same, so having kamal make assumptions about my configuration would only cost me more time.

@hschne
Copy link
Author

hschne commented Jan 27, 2024

@acidtib I appreciate that! Just to clarify, I'm not advocating for replacing the deploy.yml, I'm merely proposing changing the default values with which it is created or making those default values configurable.

You'd still be able to modify those defaults - as you are now.

@igor-alexandrov
Copy link
Contributor

I suggest implementing a post-init banner that provides information about what should be changed in deploy.yml.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants