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

feat(completion): read network zones from API #426

Merged
merged 1 commit into from
Nov 28, 2022

Conversation

apricote
Copy link
Member

We previously hard-coded the available network zones for autocompletion purposes. This makes it easy to forget to add them, or only update the list in one location (as you can see, it's currently missing us-east for the loadbalancer create call).

In this PR we replace the hardcoded list with an api call that retrieves all available network zones from the API. As there is no dedicated GET /v1/network_zones endpoint, we use the network zone referenced in the GET /v1/locations response.

We previously hard-coded the available network zones for autocompletion
purposes. This makes it easy to forget to add them, or only update the list
in one location (as you can see, it's currently missing us-east for the
loadbalancer create call).

In this PR we replace the hardcoded list with an api call that retrieves
all available network zones from the API. As there is no dedicated
`GET /v1/network_zones` endpoint, we use the network zone referenced in
the `GET /v1/locations` response.
@apricote apricote self-assigned this Nov 28, 2022
@apricote apricote merged commit 94ceb7c into main Nov 28, 2022
@apricote apricote deleted the completion-network-zone branch November 28, 2022 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants