Fetch available parameters directly from GKE when creating a cluster
When creating a cluster (https://gitlab.com/gitlab-org/gitlab-ce/issues/35954), you are asked for some parameters to choose different options (cluster size, project, etc...), and now they are inputboxes that you have to fill by yourself, figuring out which are the allowed values.
Since many of these parameters are exposed by GKE (someone only after authentication), it is a good help fetching and prefilling dropdowns with the list of the existing values, so users can simply select the intended one from the list.
Automatically get via GCP API the following parameters and fill the possible values of the dropdowns instead of inputboxes:
- Google Cloud Platform project ID
- Machine type
Parameters should be fetched as soon as possible and loaded asynchronously, to allow selection in the form. If the flow doesn't work because it is not real-time, we should still allow specifying params manually and autocomplete with possible values of the dropdown if available.
Projects are fetched in real time. The user does not need to refresh in order to see any new projects added. We show a loading icon while we fetch projects. If we run into an error while fetching, we fall back to the normal input that we have today. If we detect that the user has no projects, we inform them to create one.
Using pre-defined lists for zone and machine type, we default a value. Users can change this value or add a new one.