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

[FEATURE] Allow specifying repo config file from CLI #410

Open
oev-chrisbennett opened this issue Jun 20, 2023 · 4 comments
Open

[FEATURE] Allow specifying repo config file from CLI #410

oev-chrisbennett opened this issue Jun 20, 2023 · 4 comments
Labels
enhancement New feature or request

Comments

@oev-chrisbennett
Copy link

oev-chrisbennett commented Jun 20, 2023

Is your feature request related to a problem? Please describe.
I'd like to be able to specify a repo config file when running doppler setup so that I can easily switch between repo configs.

Describe the solution you'd like
A flag specific to doppler setup so that I can use a chosen repo config file.

# setup as usual (doppler.yaml)
doppler setup --no-interactive

# setup with chosen config (doppler.alternative.yaml)
doppler setup --no-interactive -f doppler.alternative.yaml

Describe alternatives you've considered

  • Mostly of use when using the --no-interactive flag, but would save time when having to switch between large repo configs.

Additional context

Thanks!

@oev-chrisbennett oev-chrisbennett added the enhancement New feature or request label Jun 20, 2023
@watsonian
Copy link
Contributor

@oev-chrisbennett Is the use case here a monorepo setup? We added support to help with those sorts of scenarios so you can do something like this:

setup:
  - project: cli
    config: dev
    path: .
  - project: example
    config: stg
    path: example/

Then if you run a single doppler setup --no-interactive, it'll scope the subdirectories to the correct project, so it'll automatically switch when you're in those subdirectories. Would this solve the issue you're having?

@oev-chrisbennett
Copy link
Author

hey @watsonian yes - so my use case is using a monorepo setup (normal config in doppler.yaml), but I'd like to switch all configs at once using a separate config file (doppler.alternative.yaml), i.e.:

# doppler.yaml
setup:
  - project: cli
    config: dev
    path: .
  - project: example
    config: stg
    path: example/

# doppler.alternative.yaml
setup:
  - project: cli
    config: dev-second-config
    path: .
  - project: example
    config: stg-second-config
    path: example/

so I could run

doppler setup --no-interactive

to setup everything normally, then if I wanted to change to an alternative config I could run

doppler setup --no-interactive -f doppler.alternative.yaml

In this example it's only 2 projects but it would be a great help for a monorepo setup where I need to change 10+ configs at once.

@watsonian
Copy link
Contributor

@oev-chrisbennett is the goal here swapping all services in the monorepo to a branch config for feature testing or something similar?

@oev-chrisbennett
Copy link
Author

@watsonian yes - feature testing or changing backend providers where necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

No branches or pull requests

2 participants