Skip to content

Add support for config profiles #334

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

Merged
merged 12 commits into from
May 22, 2024
Merged

Add support for config profiles #334

merged 12 commits into from
May 22, 2024

Conversation

joaopalet
Copy link
Contributor

No description provided.

joaopalet and others added 12 commits May 9, 2024 17:01
* Extract file utils and implement readFileIfExists

* Write unit tests for file utils

* Implement GetProfile

* Fix test

* Fix typo

* Remove unnecesary condition

* Fix lint

* Adjustments after review
* Implement config profile set

* Implement config profile unset

* Extend config list to show active profile

* Adjustments after review
* Add --used and --unused flags to `load-balancer list` (#308)

* initial implementation

* add testing, finish functionality

* generate docs, minor improvements

* more testing

* refactor implementation, simplify RunE

* remove unused func

* address PR comments

* generate-docs

* change filtercredentials to use enum for operation type

* address PR comments

* Onboard `load-balancer observability-credentials cleanup` (#311)

* command implementation, add testing

* rename var, generate docs

* address PR comments

* fix no credentials listing (#313)

* Integrate WinGet distribution in release pipeline (#305)

* Integrate WinGet distribution in release pipeline

* Add comment regarding skipping prereleases

* Fix link

* Configure table titles (#314)

* Update tables

* Configure colors in the less pager

* Fix title wrapping, add titles to lb

* Re-add -w argument and add titles to mongodb and pgflex options

* Add table title to config list

* Fixes and improvements to profiles functionality

---------

Co-authored-by: Diogo Ferrão <[email protected]>
Co-authored-by: Vicente Pinto <[email protected]>
* add profiles for auth settings

* adapt unit tests

* Use filepath.Join for keyring path too

---------

Co-authored-by: João Palet <[email protected]>
* initial implementation for auth warning on new profiles

* add debug logs

* simplify code, improve messages
* move reading profile to caller functions

* adapt unit tests

* adapt unit tests

* adapt unit tests
* Add --used and --unused flags to `load-balancer list` (#308)

* initial implementation

* add testing, finish functionality

* generate docs, minor improvements

* more testing

* refactor implementation, simplify RunE

* remove unused func

* address PR comments

* generate-docs

* change filtercredentials to use enum for operation type

* address PR comments

* Onboard `load-balancer observability-credentials cleanup` (#311)

* command implementation, add testing

* rename var, generate docs

* address PR comments

* fix no credentials listing (#313)

* Integrate WinGet distribution in release pipeline (#305)

* Integrate WinGet distribution in release pipeline

* Add comment regarding skipping prereleases

* Fix link

* Configure table titles (#314)

* Update tables

* Configure colors in the less pager

* Fix title wrapping, add titles to lb

* Re-add -w argument and add titles to mongodb and pgflex options

* fix(deps): update stackit sdk modules to v0.14.0 (#317)

Co-authored-by: Renovate Bot <[email protected]>

* MongoDB backup list, describe, restore-jobs (#307)

* Draft implementation mongodb backup list, describe, restore-jobs

* Fix descriptions

* Add expire date§
g

* Add docs

* Fix examples

* Add restore status

* Refactor getRestoreStatus

* Sort restore jobs array

* Add another date format to unit test§

* Implement YAML output format (#298)

* initial implementation yamlOutputFormal

* sort imports

* change yaml library

* add yaml output format

* tidy up imports

* tidy up imports

* update docs

* add yaml output for project and organization role lists

* extend contribution.md

* change yaml library

* Mongodb backup schedule, update-schedule, restore (#316)

* initial update schedule implementation

* implement update and list schedule commands, add testing

* restore command and testing

* add waiters

* generate docs

* merge changes

* address PR comments

* add custom error, fix restore examples

* Add yaml output format to mongodbflex backup commands (#319)

* add yaml output to mongodbflex commands

* update docs

* Update internal/cmd/mongodbflex/backup/describe/describe.go

Co-authored-by: João Palet <[email protected]>

* change error log

---------

Co-authored-by: João Palet <[email protected]>

* Add yaml output to lb commands (#321)

* update docs

* add yaml output

* fix(deps): update stackit sdk modules (#318)

Co-authored-by: Renovate Bot <[email protected]>

* Add SKE login command (#157)

* Add SKE login command

Co-authored-by: Maximilian Geberl <[email protected]>

* Different improvement from code review

* remove unused function

* rearrange functions and improve error messages

* Add tests for cache pkg

* Extend kubeconfig create command with flag to retrieve login kubeconfig

* small extension to the kubeconfig login description

* improve descriptions and examples

* fix yaml output

* codereview: use os.UserCacheDir instead of external lib

* codereview: drop parseInput and use parseClusterConfig directly; move cacheKey into clusterConfig

* codereview: add one nil check

* codereview: print user facing error that explains that the login command should not be used directly

* fixup! codereview: use os.UserCacheDir instead of external lib

* codereview: first try at improving the description

* generate-docs

* Add tests for login (buildRequest & parseKubeConfigToExecCredential

* cache: call Init func directly and return err

* use p.Outputf instead of cmd.Print

---------

Co-authored-by: Maximilian Geberl <[email protected]>

* Fix outputF call (#322)

* Add custom pager handling (#299)

* add custom pager handling

* ignore linter temporarily

* change condition

* add debug line

* add debug log

* add pager infos to README

* Update README.md

Co-authored-by: João Palet <[email protected]>

* edit README.md

* edit README.md

* Update README.md

Co-authored-by: Vicente Pinto <[email protected]>

* Update README.md

Co-authored-by: Vicente Pinto <[email protected]>

---------

Co-authored-by: João Palet <[email protected]>
Co-authored-by: Vicente Pinto <[email protected]>

* change marshal function to add indentation (#323)

* upgrade dependency to fix high vulnerability (#324)

* Replace createFolderIfNotExists with MkdirAll

---------

Co-authored-by: Diogo Ferrão <[email protected]>
Co-authored-by: Vicente Pinto <[email protected]>
Co-authored-by: stackit-pipeline <[email protected]>
Co-authored-by: Renovate Bot <[email protected]>
Co-authored-by: GokceGK <[email protected]>
Co-authored-by: Kumm-Kai <[email protected]>
Co-authored-by: Maximilian Geberl <[email protected]>
* Fix file path for the encoded text file

* fix unit test
@joaopalet joaopalet marked this pull request as ready for review May 22, 2024 09:52
@joaopalet joaopalet merged commit 2d0a4b7 into main May 22, 2024
3 checks passed
@joaopalet joaopalet deleted the feature/multi-config branch May 22, 2024 10:10
@DiogoFerrao DiogoFerrao restored the feature/multi-config branch May 22, 2024 13:49
DiogoFerrao added a commit that referenced this pull request May 22, 2024
DiogoFerrao added a commit that referenced this pull request May 22, 2024
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

Successfully merging this pull request may close these issues.

4 participants