Skip to content

❇️ feat: Support OKS_PROFILE environment variable#10

Merged
outscale-ykr merged 3 commits intomainfrom
feat/use-oks-profile-env
Aug 20, 2025
Merged

❇️ feat: Support OKS_PROFILE environment variable#10
outscale-ykr merged 3 commits intomainfrom
feat/use-oks-profile-env

Conversation

@emmanuel-quevillon-outscale
Copy link
Contributor

User can set OKS_PROFILE environment variable as default profile when running any oks-cli command without the need to set --profile option

User can set OKS_PROFILE envrionment variable as default profile when running any oks-cli command
without the need to set --profile option
Copy link
Contributor

@outscale-ykr outscale-ykr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dynamic shell completion no longer works after these changes.
Please refer to the shell_completions function in the utils.py file.
It need to be updated to reflect the recent changes.

@emmanuel-quevillon-outscale
Copy link
Contributor Author

@outscale-ykr changed have been made

@outscale-ykr outscale-ykr self-requested a review August 18, 2025 14:40
Copy link
Contributor

@outscale-ykr outscale-ykr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good for me.
Just one point should be added into docs:
To use autocompletion with environment-based profiles, you must
export OKS_PROFILE= before running the CLI.
Inline assignments like OKS_PROFILE=ppd oks-cli ... will not be available
to the completion engine due to shell behavior.

@emmanuel-quevillon-outscale
Copy link
Contributor Author

Looks good for me. Just one point should be added into docs: To use autocompletion with environment-based profiles, you must export OKS_PROFILE= before running the CLI. Inline assignments like OKS_PROFILE=ppd oks-cli ... will not be available to the completion engine due to shell behavior.

I agree, should this be added into the README.md file or in the OUTSCALE offical documentation?

@outscale-ykr outscale-ykr merged commit 6a974e7 into main Aug 20, 2025
3 checks passed
@outscale-ykr outscale-ykr deleted the feat/use-oks-profile-env branch August 20, 2025 11:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants