зеркало из https://github.com/Azure/ARO-RP.git
make client
This commit is contained in:
Родитель
06ed245934
Коммит
7812c70247
|
@ -1,4 +1,4 @@
|
||||||
468fa0da0a50d50640ec57843ad288af343128b39f5bf23e76e4e336580883d4 swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/stable/2020-04-30/redhatopenshift.json
|
468fa0da0a50d50640ec57843ad288af343128b39f5bf23e76e4e336580883d4 swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/stable/2020-04-30/redhatopenshift.json
|
||||||
c323c84befa5ea11da50a2407050abed6540ea01e796720bc2241604ce80567c swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/preview/2021-09-01-preview/redhatopenshift.json
|
c323c84befa5ea11da50a2407050abed6540ea01e796720bc2241604ce80567c swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/preview/2021-09-01-preview/redhatopenshift.json
|
||||||
e4e522e41855de71c0318db31cbd96c8713e7a74e7c81911bb494f0b194b3f43 swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/stable/2022-04-01/redhatopenshift.json
|
e4e522e41855de71c0318db31cbd96c8713e7a74e7c81911bb494f0b194b3f43 swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/stable/2022-04-01/redhatopenshift.json
|
||||||
70e23386b8277aea07a1babd61fb2c1252cff46ad032f700b02074fb46a58c4c swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/stable/2022-09-04/redhatopenshift.json
|
009e7ade338aa2803cb5ef94e3d6057b7093af7ed9b194e51b86e4eb71b4ac05 swagger/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/stable/2022-09-04/redhatopenshift.json
|
||||||
|
|
|
@ -122,12 +122,6 @@ type IngressProfile struct {
|
||||||
IP *string `json:"ip,omitempty"`
|
IP *string `json:"ip,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// ListString ...
|
|
||||||
type ListString struct {
|
|
||||||
autorest.Response `json:"-"`
|
|
||||||
Value *[]string `json:"value,omitempty"`
|
|
||||||
}
|
|
||||||
|
|
||||||
// MachinePool machinePool represents a MachinePool
|
// MachinePool machinePool represents a MachinePool
|
||||||
type MachinePool struct {
|
type MachinePool struct {
|
||||||
autorest.Response `json:"-"`
|
autorest.Response `json:"-"`
|
||||||
|
@ -754,8 +748,6 @@ type OpenShiftClusterProperties struct {
|
||||||
ApiserverProfile *APIServerProfile `json:"apiserverProfile,omitempty"`
|
ApiserverProfile *APIServerProfile `json:"apiserverProfile,omitempty"`
|
||||||
// IngressProfiles - The cluster ingress profiles.
|
// IngressProfiles - The cluster ingress profiles.
|
||||||
IngressProfiles *[]IngressProfile `json:"ingressProfiles,omitempty"`
|
IngressProfiles *[]IngressProfile `json:"ingressProfiles,omitempty"`
|
||||||
// InstallVersion - The cluster install version.
|
|
||||||
InstallVersion *string `json:"installVersion,omitempty"`
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// OpenShiftClustersCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
|
// OpenShiftClustersCreateOrUpdateFuture an abstraction for monitoring and retrieving the results of a
|
||||||
|
@ -945,6 +937,44 @@ func (oscu *OpenShiftClusterUpdate) UnmarshalJSON(body []byte) error {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// OpenShiftVersion openShiftVersion represents an OpenShift version that can be installed.
|
||||||
|
type OpenShiftVersion struct {
|
||||||
|
// Properties - The properties for the OpenShiftVersion resource.
|
||||||
|
Properties *OpenShiftVersionProperties `json:"properties,omitempty"`
|
||||||
|
// ID - READ-ONLY; Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
|
||||||
|
ID *string `json:"id,omitempty"`
|
||||||
|
// Name - READ-ONLY; The name of the resource
|
||||||
|
Name *string `json:"name,omitempty"`
|
||||||
|
// Type - READ-ONLY; The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
|
||||||
|
Type *string `json:"type,omitempty"`
|
||||||
|
// SystemData - READ-ONLY; Azure Resource Manager metadata containing createdBy and modifiedBy information.
|
||||||
|
SystemData *SystemData `json:"systemData,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// MarshalJSON is the custom marshaler for OpenShiftVersion.
|
||||||
|
func (osv OpenShiftVersion) MarshalJSON() ([]byte, error) {
|
||||||
|
objectMap := make(map[string]interface{})
|
||||||
|
if osv.Properties != nil {
|
||||||
|
objectMap["properties"] = osv.Properties
|
||||||
|
}
|
||||||
|
return json.Marshal(objectMap)
|
||||||
|
}
|
||||||
|
|
||||||
|
// OpenShiftVersionList openShiftVersionList represents a List of available versions.
|
||||||
|
type OpenShiftVersionList struct {
|
||||||
|
autorest.Response `json:"-"`
|
||||||
|
// Value - The List of available versions.
|
||||||
|
Value *[]OpenShiftVersion `json:"value,omitempty"`
|
||||||
|
// NextLink - Next Link to next operation.
|
||||||
|
NextLink *string `json:"nextLink,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
|
// OpenShiftVersionProperties openShiftVersionProperties represents the properties of an OpenShiftVersion.
|
||||||
|
type OpenShiftVersionProperties struct {
|
||||||
|
// Version - Version represents the version to create the cluster at.
|
||||||
|
Version *string `json:"version,omitempty"`
|
||||||
|
}
|
||||||
|
|
||||||
// Operation operation represents an RP operation.
|
// Operation operation represents an RP operation.
|
||||||
type Operation struct {
|
type Operation struct {
|
||||||
// Name - Operation name: {provider}/{resource}/{operation}.
|
// Name - Operation name: {provider}/{resource}/{operation}.
|
||||||
|
|
|
@ -27,28 +27,29 @@ import (
|
||||||
"github.com/Azure/go-autorest/tracing"
|
"github.com/Azure/go-autorest/tracing"
|
||||||
)
|
)
|
||||||
|
|
||||||
// InstallVersionsClient is the rest API for Azure Red Hat OpenShift 4
|
// OpenShiftVersionsClient is the rest API for Azure Red Hat OpenShift 4
|
||||||
type InstallVersionsClient struct {
|
type OpenShiftVersionsClient struct {
|
||||||
BaseClient
|
BaseClient
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewInstallVersionsClient creates an instance of the InstallVersionsClient client.
|
// NewOpenShiftVersionsClient creates an instance of the OpenShiftVersionsClient client.
|
||||||
func NewInstallVersionsClient(subscriptionID string) InstallVersionsClient {
|
func NewOpenShiftVersionsClient(subscriptionID string) OpenShiftVersionsClient {
|
||||||
return NewInstallVersionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
return NewOpenShiftVersionsClientWithBaseURI(DefaultBaseURI, subscriptionID)
|
||||||
}
|
}
|
||||||
|
|
||||||
// NewInstallVersionsClientWithBaseURI creates an instance of the InstallVersionsClient client using a custom endpoint.
|
// NewOpenShiftVersionsClientWithBaseURI creates an instance of the OpenShiftVersionsClient client using a custom
|
||||||
// Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure stack).
|
// endpoint. Use this when interacting with an Azure cloud that uses a non-standard base URI (sovereign clouds, Azure
|
||||||
func NewInstallVersionsClientWithBaseURI(baseURI string, subscriptionID string) InstallVersionsClient {
|
// stack).
|
||||||
return InstallVersionsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
func NewOpenShiftVersionsClientWithBaseURI(baseURI string, subscriptionID string) OpenShiftVersionsClient {
|
||||||
|
return OpenShiftVersionsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||||
}
|
}
|
||||||
|
|
||||||
// List the operation returns the installable OpenShift versions as strings.
|
// List the operation returns the installable OpenShift versions as strings.
|
||||||
// Parameters:
|
// Parameters:
|
||||||
// location - the name of Azure region.
|
// location - the name of Azure region.
|
||||||
func (client InstallVersionsClient) List(ctx context.Context, location string) (result ListString, err error) {
|
func (client OpenShiftVersionsClient) List(ctx context.Context, location string) (result OpenShiftVersionList, err error) {
|
||||||
if tracing.IsEnabled() {
|
if tracing.IsEnabled() {
|
||||||
ctx = tracing.StartSpan(ctx, fqdn+"/InstallVersionsClient.List")
|
ctx = tracing.StartSpan(ctx, fqdn+"/OpenShiftVersionsClient.List")
|
||||||
defer func() {
|
defer func() {
|
||||||
sc := -1
|
sc := -1
|
||||||
if result.Response.Response != nil {
|
if result.Response.Response != nil {
|
||||||
|
@ -62,25 +63,25 @@ func (client InstallVersionsClient) List(ctx context.Context, location string) (
|
||||||
Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
|
Constraints: []validation.Constraint{{Target: "client.SubscriptionID", Name: validation.MinLength, Rule: 1, Chain: nil}}},
|
||||||
{TargetValue: location,
|
{TargetValue: location,
|
||||||
Constraints: []validation.Constraint{{Target: "location", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
|
Constraints: []validation.Constraint{{Target: "location", Name: validation.MinLength, Rule: 1, Chain: nil}}}}); err != nil {
|
||||||
return result, validation.NewError("redhatopenshift.InstallVersionsClient", "List", err.Error())
|
return result, validation.NewError("redhatopenshift.OpenShiftVersionsClient", "List", err.Error())
|
||||||
}
|
}
|
||||||
|
|
||||||
req, err := client.ListPreparer(ctx, location)
|
req, err := client.ListPreparer(ctx, location)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
err = autorest.NewErrorWithError(err, "redhatopenshift.InstallVersionsClient", "List", nil, "Failure preparing request")
|
err = autorest.NewErrorWithError(err, "redhatopenshift.OpenShiftVersionsClient", "List", nil, "Failure preparing request")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
resp, err := client.ListSender(req)
|
resp, err := client.ListSender(req)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
result.Response = autorest.Response{Response: resp}
|
result.Response = autorest.Response{Response: resp}
|
||||||
err = autorest.NewErrorWithError(err, "redhatopenshift.InstallVersionsClient", "List", resp, "Failure sending request")
|
err = autorest.NewErrorWithError(err, "redhatopenshift.OpenShiftVersionsClient", "List", resp, "Failure sending request")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
result, err = client.ListResponder(resp)
|
result, err = client.ListResponder(resp)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
err = autorest.NewErrorWithError(err, "redhatopenshift.InstallVersionsClient", "List", resp, "Failure responding to request")
|
err = autorest.NewErrorWithError(err, "redhatopenshift.OpenShiftVersionsClient", "List", resp, "Failure responding to request")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -88,7 +89,7 @@ func (client InstallVersionsClient) List(ctx context.Context, location string) (
|
||||||
}
|
}
|
||||||
|
|
||||||
// ListPreparer prepares the List request.
|
// ListPreparer prepares the List request.
|
||||||
func (client InstallVersionsClient) ListPreparer(ctx context.Context, location string) (*http.Request, error) {
|
func (client OpenShiftVersionsClient) ListPreparer(ctx context.Context, location string) (*http.Request, error) {
|
||||||
pathParameters := map[string]interface{}{
|
pathParameters := map[string]interface{}{
|
||||||
"location": autorest.Encode("path", location),
|
"location": autorest.Encode("path", location),
|
||||||
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
"subscriptionId": autorest.Encode("path", client.SubscriptionID),
|
||||||
|
@ -109,17 +110,17 @@ func (client InstallVersionsClient) ListPreparer(ctx context.Context, location s
|
||||||
|
|
||||||
// ListSender sends the List request. The method will close the
|
// ListSender sends the List request. The method will close the
|
||||||
// http.Response Body if it receives an error.
|
// http.Response Body if it receives an error.
|
||||||
func (client InstallVersionsClient) ListSender(req *http.Request) (*http.Response, error) {
|
func (client OpenShiftVersionsClient) ListSender(req *http.Request) (*http.Response, error) {
|
||||||
return client.Send(req, azure.DoRetryWithRegistration(client.Client))
|
return client.Send(req, azure.DoRetryWithRegistration(client.Client))
|
||||||
}
|
}
|
||||||
|
|
||||||
// ListResponder handles the response to the List request. The method always
|
// ListResponder handles the response to the List request. The method always
|
||||||
// closes the http.Response Body.
|
// closes the http.Response Body.
|
||||||
func (client InstallVersionsClient) ListResponder(resp *http.Response) (result ListString, err error) {
|
func (client OpenShiftVersionsClient) ListResponder(resp *http.Response) (result OpenShiftVersionList, err error) {
|
||||||
err = autorest.Respond(
|
err = autorest.Respond(
|
||||||
resp,
|
resp,
|
||||||
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
azure.WithErrorUnlessStatusCode(http.StatusOK),
|
||||||
autorest.ByUnmarshallingJSON(&result.Value),
|
autorest.ByUnmarshallingJSON(&result),
|
||||||
autorest.ByClosing())
|
autorest.ByClosing())
|
||||||
result.Response = autorest.Response{Response: resp}
|
result.Response = autorest.Response{Response: resp}
|
||||||
return
|
return
|
|
@ -33,12 +33,12 @@ type OperationsClientAPI interface {
|
||||||
|
|
||||||
var _ OperationsClientAPI = (*redhatopenshift.OperationsClient)(nil)
|
var _ OperationsClientAPI = (*redhatopenshift.OperationsClient)(nil)
|
||||||
|
|
||||||
// InstallVersionsClientAPI contains the set of methods on the InstallVersionsClient type.
|
// OpenShiftVersionsClientAPI contains the set of methods on the OpenShiftVersionsClient type.
|
||||||
type InstallVersionsClientAPI interface {
|
type OpenShiftVersionsClientAPI interface {
|
||||||
List(ctx context.Context, location string) (result redhatopenshift.ListString, err error)
|
List(ctx context.Context, location string) (result redhatopenshift.OpenShiftVersionList, err error)
|
||||||
}
|
}
|
||||||
|
|
||||||
var _ InstallVersionsClientAPI = (*redhatopenshift.InstallVersionsClient)(nil)
|
var _ OpenShiftVersionsClientAPI = (*redhatopenshift.OpenShiftVersionsClient)(nil)
|
||||||
|
|
||||||
// OpenShiftClustersClientAPI contains the set of methods on the OpenShiftClustersClient type.
|
// OpenShiftClustersClientAPI contains the set of methods on the OpenShiftClustersClient type.
|
||||||
type OpenShiftClustersClientAPI interface {
|
type OpenShiftClustersClientAPI interface {
|
||||||
|
|
|
@ -23,7 +23,7 @@ func (m *manager) openShiftVersionFromVersion(ctx context.Context) (*api.OpenShi
|
||||||
|
|
||||||
activeOpenShiftVersions := make([]*api.OpenShiftVersion, 0)
|
activeOpenShiftVersions := make([]*api.OpenShiftVersion, 0)
|
||||||
for _, doc := range docs.OpenShiftVersionDocuments {
|
for _, doc := range docs.OpenShiftVersionDocuments {
|
||||||
if doc.OpenShiftVersion.Enabled {
|
if doc.OpenShiftVersion.Properties.Enabled {
|
||||||
activeOpenShiftVersions = append(activeOpenShiftVersions, doc.OpenShiftVersion)
|
activeOpenShiftVersions = append(activeOpenShiftVersions, doc.OpenShiftVersion)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -48,17 +48,18 @@ func (m *manager) openShiftVersionFromVersion(ctx context.Context) (*api.OpenShi
|
||||||
}
|
}
|
||||||
|
|
||||||
return &api.OpenShiftVersion{
|
return &api.OpenShiftVersion{
|
||||||
Version: version.InstallStream.Version.String(),
|
Properties: api.OpenShiftVersionProperties{
|
||||||
OpenShiftPullspec: openshiftPullSpec,
|
Version: version.InstallStream.Version.String(),
|
||||||
InstallerPullspec: installerPullSpec,
|
OpenShiftPullspec: openshiftPullSpec,
|
||||||
Enabled: true,
|
InstallerPullspec: installerPullSpec,
|
||||||
}, nil
|
Enabled: true,
|
||||||
|
}}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, active := range activeOpenShiftVersions {
|
for _, active := range activeOpenShiftVersions {
|
||||||
if requestedInstallVersion == active.Version {
|
if requestedInstallVersion == active.Properties.Version {
|
||||||
if m.installViaHive {
|
if m.installViaHive {
|
||||||
active.OpenShiftPullspec = strings.Replace(active.OpenShiftPullspec, "quay.io", m.env.ACRDomain(), 1)
|
active.Properties.OpenShiftPullspec = strings.Replace(active.Properties.OpenShiftPullspec, "quay.io", m.env.ACRDomain(), 1)
|
||||||
}
|
}
|
||||||
return active, nil
|
return active, nil
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,9 +50,11 @@ func TestGetOpenShiftVersionFromVersion(t *testing.T) {
|
||||||
},
|
},
|
||||||
wantErrString: "",
|
wantErrString: "",
|
||||||
want: &api.OpenShiftVersion{
|
want: &api.OpenShiftVersion{
|
||||||
Version: version.InstallStream.Version.String(),
|
Properties: api.OpenShiftVersionProperties{
|
||||||
OpenShiftPullspec: version.InstallStream.PullSpec,
|
Version: version.InstallStream.Version.String(),
|
||||||
InstallerPullspec: fmt.Sprintf("%s/aro-installer:release-%d.%d", testACRDomain, version.InstallStream.Version.V[0], version.InstallStream.Version.V[1]),
|
OpenShiftPullspec: version.InstallStream.PullSpec,
|
||||||
|
InstallerPullspec: fmt.Sprintf("%s/aro-installer:release-%d.%d", testACRDomain, version.InstallStream.Version.V[0], version.InstallStream.Version.V[1]),
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
@ -61,13 +63,17 @@ func TestGetOpenShiftVersionFromVersion(t *testing.T) {
|
||||||
f.AddOpenShiftVersionDocuments(
|
f.AddOpenShiftVersionDocuments(
|
||||||
&api.OpenShiftVersionDocument{
|
&api.OpenShiftVersionDocument{
|
||||||
OpenShiftVersion: &api.OpenShiftVersion{
|
OpenShiftVersion: &api.OpenShiftVersion{
|
||||||
Version: "4.10.20",
|
Properties: api.OpenShiftVersionProperties{
|
||||||
Enabled: true,
|
Version: "4.10.20",
|
||||||
|
Enabled: true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
}, &api.OpenShiftVersionDocument{
|
}, &api.OpenShiftVersionDocument{
|
||||||
OpenShiftVersion: &api.OpenShiftVersion{
|
OpenShiftVersion: &api.OpenShiftVersion{
|
||||||
Version: "4.10.27",
|
Properties: api.OpenShiftVersionProperties{
|
||||||
Enabled: true,
|
Version: "4.10.27",
|
||||||
|
Enabled: true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
@ -123,9 +129,9 @@ func TestGetOpenShiftVersionFromVersion(t *testing.T) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if tt.want != nil {
|
if tt.want != nil {
|
||||||
assert.Equal(t, tt.want.Version, version.Version, "Version does not match")
|
assert.Equal(t, tt.want.Properties.Version, version.Properties.Version, "Version does not match")
|
||||||
assert.Equal(t, tt.want.OpenShiftPullspec, version.OpenShiftPullspec, "OpenShiftPullspec does not match")
|
assert.Equal(t, tt.want.Properties.OpenShiftPullspec, version.Properties.OpenShiftPullspec, "OpenShiftPullspec does not match")
|
||||||
assert.Equal(t, tt.want.InstallerPullspec, version.InstallerPullspec, "InstallerPullspec does not match")
|
assert.Equal(t, tt.want.Properties.InstallerPullspec, version.Properties.InstallerPullspec, "InstallerPullspec does not match")
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,7 @@ from azure.mgmt.core import ARMPipelineClient
|
||||||
|
|
||||||
from . import models
|
from . import models
|
||||||
from ._configuration import AzureRedHatOpenShiftClientConfiguration
|
from ._configuration import AzureRedHatOpenShiftClientConfiguration
|
||||||
from .operations import InstallVersionsOperations, MachinePoolsOperations, OpenShiftClustersOperations, Operations, SecretsOperations, SyncIdentityProvidersOperations, SyncSetsOperations
|
from .operations import MachinePoolsOperations, OpenShiftClustersOperations, OpenShiftVersionsOperations, Operations, SecretsOperations, SyncIdentityProvidersOperations, SyncSetsOperations
|
||||||
|
|
||||||
if TYPE_CHECKING:
|
if TYPE_CHECKING:
|
||||||
# pylint: disable=unused-import,ungrouped-imports
|
# pylint: disable=unused-import,ungrouped-imports
|
||||||
|
@ -37,9 +37,9 @@ class AzureRedHatOpenShiftClient(object): # pylint: disable=too-many-instance
|
||||||
|
|
||||||
:ivar operations: Operations operations
|
:ivar operations: Operations operations
|
||||||
:vartype operations: azure.mgmt.redhatopenshift.v2022_09_04.operations.Operations
|
:vartype operations: azure.mgmt.redhatopenshift.v2022_09_04.operations.Operations
|
||||||
:ivar install_versions: InstallVersionsOperations operations
|
:ivar open_shift_versions: OpenShiftVersionsOperations operations
|
||||||
:vartype install_versions:
|
:vartype open_shift_versions:
|
||||||
azure.mgmt.redhatopenshift.v2022_09_04.operations.InstallVersionsOperations
|
azure.mgmt.redhatopenshift.v2022_09_04.operations.OpenShiftVersionsOperations
|
||||||
:ivar open_shift_clusters: OpenShiftClustersOperations operations
|
:ivar open_shift_clusters: OpenShiftClustersOperations operations
|
||||||
:vartype open_shift_clusters:
|
:vartype open_shift_clusters:
|
||||||
azure.mgmt.redhatopenshift.v2022_09_04.operations.OpenShiftClustersOperations
|
azure.mgmt.redhatopenshift.v2022_09_04.operations.OpenShiftClustersOperations
|
||||||
|
@ -82,7 +82,7 @@ class AzureRedHatOpenShiftClient(object): # pylint: disable=too-many-instance
|
||||||
self._deserialize = Deserializer(client_models)
|
self._deserialize = Deserializer(client_models)
|
||||||
self._serialize.client_side_validation = False
|
self._serialize.client_side_validation = False
|
||||||
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
|
self.operations = Operations(self._client, self._config, self._serialize, self._deserialize)
|
||||||
self.install_versions = InstallVersionsOperations(self._client, self._config, self._serialize, self._deserialize)
|
self.open_shift_versions = OpenShiftVersionsOperations(self._client, self._config, self._serialize, self._deserialize)
|
||||||
self.open_shift_clusters = OpenShiftClustersOperations(self._client, self._config, self._serialize, self._deserialize)
|
self.open_shift_clusters = OpenShiftClustersOperations(self._client, self._config, self._serialize, self._deserialize)
|
||||||
self.machine_pools = MachinePoolsOperations(self._client, self._config, self._serialize, self._deserialize)
|
self.machine_pools = MachinePoolsOperations(self._client, self._config, self._serialize, self._deserialize)
|
||||||
self.secrets = SecretsOperations(self._client, self._config, self._serialize, self._deserialize)
|
self.secrets = SecretsOperations(self._client, self._config, self._serialize, self._deserialize)
|
||||||
|
|
|
@ -31,6 +31,9 @@ try:
|
||||||
from ._models_py3 import OpenShiftClusterCredentials
|
from ._models_py3 import OpenShiftClusterCredentials
|
||||||
from ._models_py3 import OpenShiftClusterList
|
from ._models_py3 import OpenShiftClusterList
|
||||||
from ._models_py3 import OpenShiftClusterUpdate
|
from ._models_py3 import OpenShiftClusterUpdate
|
||||||
|
from ._models_py3 import OpenShiftVersion
|
||||||
|
from ._models_py3 import OpenShiftVersionList
|
||||||
|
from ._models_py3 import OpenShiftVersionProperties
|
||||||
from ._models_py3 import Operation
|
from ._models_py3 import Operation
|
||||||
from ._models_py3 import OperationList
|
from ._models_py3 import OperationList
|
||||||
from ._models_py3 import ProxyResource
|
from ._models_py3 import ProxyResource
|
||||||
|
@ -65,6 +68,9 @@ except (SyntaxError, ImportError):
|
||||||
from ._models import OpenShiftClusterCredentials # type: ignore
|
from ._models import OpenShiftClusterCredentials # type: ignore
|
||||||
from ._models import OpenShiftClusterList # type: ignore
|
from ._models import OpenShiftClusterList # type: ignore
|
||||||
from ._models import OpenShiftClusterUpdate # type: ignore
|
from ._models import OpenShiftClusterUpdate # type: ignore
|
||||||
|
from ._models import OpenShiftVersion # type: ignore
|
||||||
|
from ._models import OpenShiftVersionList # type: ignore
|
||||||
|
from ._models import OpenShiftVersionProperties # type: ignore
|
||||||
from ._models import Operation # type: ignore
|
from ._models import Operation # type: ignore
|
||||||
from ._models import OperationList # type: ignore
|
from ._models import OperationList # type: ignore
|
||||||
from ._models import ProxyResource # type: ignore
|
from ._models import ProxyResource # type: ignore
|
||||||
|
@ -108,6 +114,9 @@ __all__ = [
|
||||||
'OpenShiftClusterCredentials',
|
'OpenShiftClusterCredentials',
|
||||||
'OpenShiftClusterList',
|
'OpenShiftClusterList',
|
||||||
'OpenShiftClusterUpdate',
|
'OpenShiftClusterUpdate',
|
||||||
|
'OpenShiftVersion',
|
||||||
|
'OpenShiftVersionList',
|
||||||
|
'OpenShiftVersionProperties',
|
||||||
'Operation',
|
'Operation',
|
||||||
'OperationList',
|
'OperationList',
|
||||||
'ProxyResource',
|
'ProxyResource',
|
||||||
|
|
|
@ -619,8 +619,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
||||||
:ivar ingress_profiles: The cluster ingress profiles.
|
:ivar ingress_profiles: The cluster ingress profiles.
|
||||||
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:ivar install_version: The cluster install version.
|
|
||||||
:vartype install_version: str
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
_validation = {
|
_validation = {
|
||||||
|
@ -647,7 +645,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
||||||
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
||||||
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
||||||
'install_version': {'key': 'properties.installVersion', 'type': 'str'},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
@ -681,8 +678,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
:keyword ingress_profiles: The cluster ingress profiles.
|
:keyword ingress_profiles: The cluster ingress profiles.
|
||||||
:paramtype ingress_profiles:
|
:paramtype ingress_profiles:
|
||||||
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:keyword install_version: The cluster install version.
|
|
||||||
:paramtype install_version: str
|
|
||||||
"""
|
"""
|
||||||
super(OpenShiftCluster, self).__init__(**kwargs)
|
super(OpenShiftCluster, self).__init__(**kwargs)
|
||||||
self.provisioning_state = kwargs.get('provisioning_state', None)
|
self.provisioning_state = kwargs.get('provisioning_state', None)
|
||||||
|
@ -694,7 +689,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
self.worker_profiles = kwargs.get('worker_profiles', None)
|
self.worker_profiles = kwargs.get('worker_profiles', None)
|
||||||
self.apiserver_profile = kwargs.get('apiserver_profile', None)
|
self.apiserver_profile = kwargs.get('apiserver_profile', None)
|
||||||
self.ingress_profiles = kwargs.get('ingress_profiles', None)
|
self.ingress_profiles = kwargs.get('ingress_profiles', None)
|
||||||
self.install_version = kwargs.get('install_version', None)
|
|
||||||
|
|
||||||
|
|
||||||
class OpenShiftClusterAdminKubeconfig(msrest.serialization.Model):
|
class OpenShiftClusterAdminKubeconfig(msrest.serialization.Model):
|
||||||
|
@ -808,8 +802,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
||||||
:ivar ingress_profiles: The cluster ingress profiles.
|
:ivar ingress_profiles: The cluster ingress profiles.
|
||||||
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:ivar install_version: The cluster install version.
|
|
||||||
:vartype install_version: str
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
_validation = {
|
_validation = {
|
||||||
|
@ -828,7 +820,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
||||||
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
||||||
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
||||||
'install_version': {'key': 'properties.installVersion', 'type': 'str'},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
@ -860,8 +851,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
:keyword ingress_profiles: The cluster ingress profiles.
|
:keyword ingress_profiles: The cluster ingress profiles.
|
||||||
:paramtype ingress_profiles:
|
:paramtype ingress_profiles:
|
||||||
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:keyword install_version: The cluster install version.
|
|
||||||
:paramtype install_version: str
|
|
||||||
"""
|
"""
|
||||||
super(OpenShiftClusterUpdate, self).__init__(**kwargs)
|
super(OpenShiftClusterUpdate, self).__init__(**kwargs)
|
||||||
self.tags = kwargs.get('tags', None)
|
self.tags = kwargs.get('tags', None)
|
||||||
|
@ -875,7 +864,106 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
self.worker_profiles = kwargs.get('worker_profiles', None)
|
self.worker_profiles = kwargs.get('worker_profiles', None)
|
||||||
self.apiserver_profile = kwargs.get('apiserver_profile', None)
|
self.apiserver_profile = kwargs.get('apiserver_profile', None)
|
||||||
self.ingress_profiles = kwargs.get('ingress_profiles', None)
|
self.ingress_profiles = kwargs.get('ingress_profiles', None)
|
||||||
self.install_version = kwargs.get('install_version', None)
|
|
||||||
|
|
||||||
|
class OpenShiftVersion(ProxyResource):
|
||||||
|
"""OpenShiftVersion represents an OpenShift version that can be installed.
|
||||||
|
|
||||||
|
Variables are only populated by the server, and will be ignored when sending a request.
|
||||||
|
|
||||||
|
:ivar id: Fully qualified resource ID for the resource. Ex -
|
||||||
|
/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
|
||||||
|
:vartype id: str
|
||||||
|
:ivar name: The name of the resource.
|
||||||
|
:vartype name: str
|
||||||
|
:ivar type: The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or
|
||||||
|
"Microsoft.Storage/storageAccounts".
|
||||||
|
:vartype type: str
|
||||||
|
:ivar system_data: Azure Resource Manager metadata containing createdBy and modifiedBy
|
||||||
|
information.
|
||||||
|
:vartype system_data: ~azure.mgmt.redhatopenshift.v2022_09_04.models.SystemData
|
||||||
|
:ivar properties: The properties for the OpenShiftVersion resource.
|
||||||
|
:vartype properties: ~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersionProperties
|
||||||
|
"""
|
||||||
|
|
||||||
|
_validation = {
|
||||||
|
'id': {'readonly': True},
|
||||||
|
'name': {'readonly': True},
|
||||||
|
'type': {'readonly': True},
|
||||||
|
'system_data': {'readonly': True},
|
||||||
|
}
|
||||||
|
|
||||||
|
_attribute_map = {
|
||||||
|
'id': {'key': 'id', 'type': 'str'},
|
||||||
|
'name': {'key': 'name', 'type': 'str'},
|
||||||
|
'type': {'key': 'type', 'type': 'str'},
|
||||||
|
'system_data': {'key': 'systemData', 'type': 'SystemData'},
|
||||||
|
'properties': {'key': 'properties', 'type': 'OpenShiftVersionProperties'},
|
||||||
|
}
|
||||||
|
|
||||||
|
def __init__(
|
||||||
|
self,
|
||||||
|
**kwargs
|
||||||
|
):
|
||||||
|
"""
|
||||||
|
:keyword properties: The properties for the OpenShiftVersion resource.
|
||||||
|
:paramtype properties:
|
||||||
|
~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersionProperties
|
||||||
|
"""
|
||||||
|
super(OpenShiftVersion, self).__init__(**kwargs)
|
||||||
|
self.properties = kwargs.get('properties', None)
|
||||||
|
|
||||||
|
|
||||||
|
class OpenShiftVersionList(msrest.serialization.Model):
|
||||||
|
"""OpenShiftVersionList represents a List of available versions.
|
||||||
|
|
||||||
|
:ivar value: The List of available versions.
|
||||||
|
:vartype value: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersion]
|
||||||
|
:ivar next_link: Next Link to next operation.
|
||||||
|
:vartype next_link: str
|
||||||
|
"""
|
||||||
|
|
||||||
|
_attribute_map = {
|
||||||
|
'value': {'key': 'value', 'type': '[OpenShiftVersion]'},
|
||||||
|
'next_link': {'key': 'nextLink', 'type': 'str'},
|
||||||
|
}
|
||||||
|
|
||||||
|
def __init__(
|
||||||
|
self,
|
||||||
|
**kwargs
|
||||||
|
):
|
||||||
|
"""
|
||||||
|
:keyword value: The List of available versions.
|
||||||
|
:paramtype value: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersion]
|
||||||
|
:keyword next_link: Next Link to next operation.
|
||||||
|
:paramtype next_link: str
|
||||||
|
"""
|
||||||
|
super(OpenShiftVersionList, self).__init__(**kwargs)
|
||||||
|
self.value = kwargs.get('value', None)
|
||||||
|
self.next_link = kwargs.get('next_link', None)
|
||||||
|
|
||||||
|
|
||||||
|
class OpenShiftVersionProperties(msrest.serialization.Model):
|
||||||
|
"""OpenShiftVersionProperties represents the properties of an OpenShiftVersion.
|
||||||
|
|
||||||
|
:ivar version: Version represents the version to create the cluster at.
|
||||||
|
:vartype version: str
|
||||||
|
"""
|
||||||
|
|
||||||
|
_attribute_map = {
|
||||||
|
'version': {'key': 'version', 'type': 'str'},
|
||||||
|
}
|
||||||
|
|
||||||
|
def __init__(
|
||||||
|
self,
|
||||||
|
**kwargs
|
||||||
|
):
|
||||||
|
"""
|
||||||
|
:keyword version: Version represents the version to create the cluster at.
|
||||||
|
:paramtype version: str
|
||||||
|
"""
|
||||||
|
super(OpenShiftVersionProperties, self).__init__(**kwargs)
|
||||||
|
self.version = kwargs.get('version', None)
|
||||||
|
|
||||||
|
|
||||||
class Operation(msrest.serialization.Model):
|
class Operation(msrest.serialization.Model):
|
||||||
|
|
|
@ -668,8 +668,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
||||||
:ivar ingress_profiles: The cluster ingress profiles.
|
:ivar ingress_profiles: The cluster ingress profiles.
|
||||||
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:ivar install_version: The cluster install version.
|
|
||||||
:vartype install_version: str
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
_validation = {
|
_validation = {
|
||||||
|
@ -696,7 +694,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
||||||
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
||||||
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
||||||
'install_version': {'key': 'properties.installVersion', 'type': 'str'},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
@ -713,7 +710,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
worker_profiles: Optional[List["WorkerProfile"]] = None,
|
worker_profiles: Optional[List["WorkerProfile"]] = None,
|
||||||
apiserver_profile: Optional["APIServerProfile"] = None,
|
apiserver_profile: Optional["APIServerProfile"] = None,
|
||||||
ingress_profiles: Optional[List["IngressProfile"]] = None,
|
ingress_profiles: Optional[List["IngressProfile"]] = None,
|
||||||
install_version: Optional[str] = None,
|
|
||||||
**kwargs
|
**kwargs
|
||||||
):
|
):
|
||||||
"""
|
"""
|
||||||
|
@ -743,8 +739,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
:keyword ingress_profiles: The cluster ingress profiles.
|
:keyword ingress_profiles: The cluster ingress profiles.
|
||||||
:paramtype ingress_profiles:
|
:paramtype ingress_profiles:
|
||||||
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:keyword install_version: The cluster install version.
|
|
||||||
:paramtype install_version: str
|
|
||||||
"""
|
"""
|
||||||
super(OpenShiftCluster, self).__init__(tags=tags, location=location, **kwargs)
|
super(OpenShiftCluster, self).__init__(tags=tags, location=location, **kwargs)
|
||||||
self.provisioning_state = provisioning_state
|
self.provisioning_state = provisioning_state
|
||||||
|
@ -756,7 +750,6 @@ class OpenShiftCluster(TrackedResource):
|
||||||
self.worker_profiles = worker_profiles
|
self.worker_profiles = worker_profiles
|
||||||
self.apiserver_profile = apiserver_profile
|
self.apiserver_profile = apiserver_profile
|
||||||
self.ingress_profiles = ingress_profiles
|
self.ingress_profiles = ingress_profiles
|
||||||
self.install_version = install_version
|
|
||||||
|
|
||||||
|
|
||||||
class OpenShiftClusterAdminKubeconfig(msrest.serialization.Model):
|
class OpenShiftClusterAdminKubeconfig(msrest.serialization.Model):
|
||||||
|
@ -878,8 +871,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
:vartype apiserver_profile: ~azure.mgmt.redhatopenshift.v2022_09_04.models.APIServerProfile
|
||||||
:ivar ingress_profiles: The cluster ingress profiles.
|
:ivar ingress_profiles: The cluster ingress profiles.
|
||||||
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
:vartype ingress_profiles: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:ivar install_version: The cluster install version.
|
|
||||||
:vartype install_version: str
|
|
||||||
"""
|
"""
|
||||||
|
|
||||||
_validation = {
|
_validation = {
|
||||||
|
@ -898,7 +889,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
'worker_profiles': {'key': 'properties.workerProfiles', 'type': '[WorkerProfile]'},
|
||||||
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
'apiserver_profile': {'key': 'properties.apiserverProfile', 'type': 'APIServerProfile'},
|
||||||
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
'ingress_profiles': {'key': 'properties.ingressProfiles', 'type': '[IngressProfile]'},
|
||||||
'install_version': {'key': 'properties.installVersion', 'type': 'str'},
|
|
||||||
}
|
}
|
||||||
|
|
||||||
def __init__(
|
def __init__(
|
||||||
|
@ -914,7 +904,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
worker_profiles: Optional[List["WorkerProfile"]] = None,
|
worker_profiles: Optional[List["WorkerProfile"]] = None,
|
||||||
apiserver_profile: Optional["APIServerProfile"] = None,
|
apiserver_profile: Optional["APIServerProfile"] = None,
|
||||||
ingress_profiles: Optional[List["IngressProfile"]] = None,
|
ingress_profiles: Optional[List["IngressProfile"]] = None,
|
||||||
install_version: Optional[str] = None,
|
|
||||||
**kwargs
|
**kwargs
|
||||||
):
|
):
|
||||||
"""
|
"""
|
||||||
|
@ -942,8 +931,6 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
:keyword ingress_profiles: The cluster ingress profiles.
|
:keyword ingress_profiles: The cluster ingress profiles.
|
||||||
:paramtype ingress_profiles:
|
:paramtype ingress_profiles:
|
||||||
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
list[~azure.mgmt.redhatopenshift.v2022_09_04.models.IngressProfile]
|
||||||
:keyword install_version: The cluster install version.
|
|
||||||
:paramtype install_version: str
|
|
||||||
"""
|
"""
|
||||||
super(OpenShiftClusterUpdate, self).__init__(**kwargs)
|
super(OpenShiftClusterUpdate, self).__init__(**kwargs)
|
||||||
self.tags = tags
|
self.tags = tags
|
||||||
|
@ -957,7 +944,113 @@ class OpenShiftClusterUpdate(msrest.serialization.Model):
|
||||||
self.worker_profiles = worker_profiles
|
self.worker_profiles = worker_profiles
|
||||||
self.apiserver_profile = apiserver_profile
|
self.apiserver_profile = apiserver_profile
|
||||||
self.ingress_profiles = ingress_profiles
|
self.ingress_profiles = ingress_profiles
|
||||||
self.install_version = install_version
|
|
||||||
|
|
||||||
|
class OpenShiftVersion(ProxyResource):
|
||||||
|
"""OpenShiftVersion represents an OpenShift version that can be installed.
|
||||||
|
|
||||||
|
Variables are only populated by the server, and will be ignored when sending a request.
|
||||||
|
|
||||||
|
:ivar id: Fully qualified resource ID for the resource. Ex -
|
||||||
|
/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
|
||||||
|
:vartype id: str
|
||||||
|
:ivar name: The name of the resource.
|
||||||
|
:vartype name: str
|
||||||
|
:ivar type: The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or
|
||||||
|
"Microsoft.Storage/storageAccounts".
|
||||||
|
:vartype type: str
|
||||||
|
:ivar system_data: Azure Resource Manager metadata containing createdBy and modifiedBy
|
||||||
|
information.
|
||||||
|
:vartype system_data: ~azure.mgmt.redhatopenshift.v2022_09_04.models.SystemData
|
||||||
|
:ivar properties: The properties for the OpenShiftVersion resource.
|
||||||
|
:vartype properties: ~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersionProperties
|
||||||
|
"""
|
||||||
|
|
||||||
|
_validation = {
|
||||||
|
'id': {'readonly': True},
|
||||||
|
'name': {'readonly': True},
|
||||||
|
'type': {'readonly': True},
|
||||||
|
'system_data': {'readonly': True},
|
||||||
|
}
|
||||||
|
|
||||||
|
_attribute_map = {
|
||||||
|
'id': {'key': 'id', 'type': 'str'},
|
||||||
|
'name': {'key': 'name', 'type': 'str'},
|
||||||
|
'type': {'key': 'type', 'type': 'str'},
|
||||||
|
'system_data': {'key': 'systemData', 'type': 'SystemData'},
|
||||||
|
'properties': {'key': 'properties', 'type': 'OpenShiftVersionProperties'},
|
||||||
|
}
|
||||||
|
|
||||||
|
def __init__(
|
||||||
|
self,
|
||||||
|
*,
|
||||||
|
properties: Optional["OpenShiftVersionProperties"] = None,
|
||||||
|
**kwargs
|
||||||
|
):
|
||||||
|
"""
|
||||||
|
:keyword properties: The properties for the OpenShiftVersion resource.
|
||||||
|
:paramtype properties:
|
||||||
|
~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersionProperties
|
||||||
|
"""
|
||||||
|
super(OpenShiftVersion, self).__init__(**kwargs)
|
||||||
|
self.properties = properties
|
||||||
|
|
||||||
|
|
||||||
|
class OpenShiftVersionList(msrest.serialization.Model):
|
||||||
|
"""OpenShiftVersionList represents a List of available versions.
|
||||||
|
|
||||||
|
:ivar value: The List of available versions.
|
||||||
|
:vartype value: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersion]
|
||||||
|
:ivar next_link: Next Link to next operation.
|
||||||
|
:vartype next_link: str
|
||||||
|
"""
|
||||||
|
|
||||||
|
_attribute_map = {
|
||||||
|
'value': {'key': 'value', 'type': '[OpenShiftVersion]'},
|
||||||
|
'next_link': {'key': 'nextLink', 'type': 'str'},
|
||||||
|
}
|
||||||
|
|
||||||
|
def __init__(
|
||||||
|
self,
|
||||||
|
*,
|
||||||
|
value: Optional[List["OpenShiftVersion"]] = None,
|
||||||
|
next_link: Optional[str] = None,
|
||||||
|
**kwargs
|
||||||
|
):
|
||||||
|
"""
|
||||||
|
:keyword value: The List of available versions.
|
||||||
|
:paramtype value: list[~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersion]
|
||||||
|
:keyword next_link: Next Link to next operation.
|
||||||
|
:paramtype next_link: str
|
||||||
|
"""
|
||||||
|
super(OpenShiftVersionList, self).__init__(**kwargs)
|
||||||
|
self.value = value
|
||||||
|
self.next_link = next_link
|
||||||
|
|
||||||
|
|
||||||
|
class OpenShiftVersionProperties(msrest.serialization.Model):
|
||||||
|
"""OpenShiftVersionProperties represents the properties of an OpenShiftVersion.
|
||||||
|
|
||||||
|
:ivar version: Version represents the version to create the cluster at.
|
||||||
|
:vartype version: str
|
||||||
|
"""
|
||||||
|
|
||||||
|
_attribute_map = {
|
||||||
|
'version': {'key': 'version', 'type': 'str'},
|
||||||
|
}
|
||||||
|
|
||||||
|
def __init__(
|
||||||
|
self,
|
||||||
|
*,
|
||||||
|
version: Optional[str] = None,
|
||||||
|
**kwargs
|
||||||
|
):
|
||||||
|
"""
|
||||||
|
:keyword version: Version represents the version to create the cluster at.
|
||||||
|
:paramtype version: str
|
||||||
|
"""
|
||||||
|
super(OpenShiftVersionProperties, self).__init__(**kwargs)
|
||||||
|
self.version = version
|
||||||
|
|
||||||
|
|
||||||
class Operation(msrest.serialization.Model):
|
class Operation(msrest.serialization.Model):
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
# --------------------------------------------------------------------------
|
# --------------------------------------------------------------------------
|
||||||
|
|
||||||
from ._operations import Operations
|
from ._operations import Operations
|
||||||
from ._install_versions_operations import InstallVersionsOperations
|
from ._open_shift_versions_operations import OpenShiftVersionsOperations
|
||||||
from ._open_shift_clusters_operations import OpenShiftClustersOperations
|
from ._open_shift_clusters_operations import OpenShiftClustersOperations
|
||||||
from ._machine_pools_operations import MachinePoolsOperations
|
from ._machine_pools_operations import MachinePoolsOperations
|
||||||
from ._secrets_operations import SecretsOperations
|
from ._secrets_operations import SecretsOperations
|
||||||
|
@ -24,7 +24,7 @@ from ._sync_sets_operations import SyncSetsOperations
|
||||||
|
|
||||||
__all__ = [
|
__all__ = [
|
||||||
'Operations',
|
'Operations',
|
||||||
'InstallVersionsOperations',
|
'OpenShiftVersionsOperations',
|
||||||
'OpenShiftClustersOperations',
|
'OpenShiftClustersOperations',
|
||||||
'MachinePoolsOperations',
|
'MachinePoolsOperations',
|
||||||
'SecretsOperations',
|
'SecretsOperations',
|
||||||
|
|
|
@ -30,7 +30,7 @@ from .._vendor import _convert_request, _format_url_section
|
||||||
|
|
||||||
if TYPE_CHECKING:
|
if TYPE_CHECKING:
|
||||||
# pylint: disable=unused-import,ungrouped-imports
|
# pylint: disable=unused-import,ungrouped-imports
|
||||||
from typing import Any, Callable, Dict, List, Optional, TypeVar
|
from typing import Any, Callable, Dict, Optional, TypeVar
|
||||||
T = TypeVar('T')
|
T = TypeVar('T')
|
||||||
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]]
|
ClsType = Optional[Callable[[PipelineResponse[HttpRequest, HttpResponse], T, Dict[str, Any]], Any]]
|
||||||
|
|
||||||
|
@ -73,8 +73,8 @@ def build_list_request(
|
||||||
)
|
)
|
||||||
|
|
||||||
# fmt: on
|
# fmt: on
|
||||||
class InstallVersionsOperations(object):
|
class OpenShiftVersionsOperations(object):
|
||||||
"""InstallVersionsOperations operations.
|
"""OpenShiftVersionsOperations operations.
|
||||||
|
|
||||||
You should not instantiate this class directly. Instead, you should create a Client instance that
|
You should not instantiate this class directly. Instead, you should create a Client instance that
|
||||||
instantiates it for you and attaches it as an attribute.
|
instantiates it for you and attaches it as an attribute.
|
||||||
|
@ -101,7 +101,7 @@ class InstallVersionsOperations(object):
|
||||||
location, # type: str
|
location, # type: str
|
||||||
**kwargs # type: Any
|
**kwargs # type: Any
|
||||||
):
|
):
|
||||||
# type: (...) -> List[str]
|
# type: (...) -> "_models.OpenShiftVersionList"
|
||||||
"""Lists all OpenShift versions available to install in the specified location.
|
"""Lists all OpenShift versions available to install in the specified location.
|
||||||
|
|
||||||
The operation returns the installable OpenShift versions as strings.
|
The operation returns the installable OpenShift versions as strings.
|
||||||
|
@ -109,11 +109,11 @@ class InstallVersionsOperations(object):
|
||||||
:param location: The name of Azure region.
|
:param location: The name of Azure region.
|
||||||
:type location: str
|
:type location: str
|
||||||
:keyword callable cls: A custom type or function that will be passed the direct response
|
:keyword callable cls: A custom type or function that will be passed the direct response
|
||||||
:return: list of str, or the result of cls(response)
|
:return: OpenShiftVersionList, or the result of cls(response)
|
||||||
:rtype: list[str]
|
:rtype: ~azure.mgmt.redhatopenshift.v2022_09_04.models.OpenShiftVersionList
|
||||||
:raises: ~azure.core.exceptions.HttpResponseError
|
:raises: ~azure.core.exceptions.HttpResponseError
|
||||||
"""
|
"""
|
||||||
cls = kwargs.pop('cls', None) # type: ClsType[List[str]]
|
cls = kwargs.pop('cls', None) # type: ClsType["_models.OpenShiftVersionList"]
|
||||||
error_map = {
|
error_map = {
|
||||||
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
|
401: ClientAuthenticationError, 404: ResourceNotFoundError, 409: ResourceExistsError
|
||||||
}
|
}
|
||||||
|
@ -142,7 +142,7 @@ class InstallVersionsOperations(object):
|
||||||
map_error(status_code=response.status_code, response=response, error_map=error_map)
|
map_error(status_code=response.status_code, response=response, error_map=error_map)
|
||||||
raise HttpResponseError(response=response, error_format=ARMErrorFormat)
|
raise HttpResponseError(response=response, error_format=ARMErrorFormat)
|
||||||
|
|
||||||
deserialized = self._deserialize('[str]', pipeline_response)
|
deserialized = self._deserialize('OpenShiftVersionList', pipeline_response)
|
||||||
|
|
||||||
if cls:
|
if cls:
|
||||||
return cls(pipeline_response, deserialized, {})
|
return cls(pipeline_response, deserialized, {})
|
|
@ -6,9 +6,15 @@
|
||||||
},
|
},
|
||||||
"responses": {
|
"responses": {
|
||||||
"200": {
|
"200": {
|
||||||
"body": [
|
"body": {
|
||||||
"4.10.20"
|
"value": [
|
||||||
]
|
{
|
||||||
|
"properties": {
|
||||||
|
"version": "4.10.20"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -56,11 +56,11 @@
|
||||||
"/subscriptions/{subscriptionId}/providers/Microsoft.RedHatOpenShift/locations/{location}/listinstallversions": {
|
"/subscriptions/{subscriptionId}/providers/Microsoft.RedHatOpenShift/locations/{location}/listinstallversions": {
|
||||||
"get": {
|
"get": {
|
||||||
"tags": [
|
"tags": [
|
||||||
"InstallVersions"
|
"OpenShiftVersions"
|
||||||
],
|
],
|
||||||
"summary": "Lists all OpenShift versions available to install in the specified location.",
|
"summary": "Lists all OpenShift versions available to install in the specified location.",
|
||||||
"description": "The operation returns the installable OpenShift versions as strings.",
|
"description": "The operation returns the installable OpenShift versions as strings.",
|
||||||
"operationId": "InstallVersions_List",
|
"operationId": "OpenShiftVersions_List",
|
||||||
"parameters": [
|
"parameters": [
|
||||||
{
|
{
|
||||||
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter"
|
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter"
|
||||||
|
@ -76,7 +76,7 @@
|
||||||
"200": {
|
"200": {
|
||||||
"description": "OK",
|
"description": "OK",
|
||||||
"schema": {
|
"schema": {
|
||||||
"$ref": "#/definitions/InstallVersions"
|
"$ref": "#/definitions/OpenShiftVersionList"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"default": {
|
"default": {
|
||||||
|
@ -88,7 +88,7 @@
|
||||||
},
|
},
|
||||||
"x-ms-examples": {
|
"x-ms-examples": {
|
||||||
"Lists all OpenShift versions available to install in the specified location.": {
|
"Lists all OpenShift versions available to install in the specified location.": {
|
||||||
"$ref": "./examples/InstallVersions_List.json"
|
"$ref": "./examples/OpenShiftVersions_List.json"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1801,18 +1801,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"InstallVersion": {
|
|
||||||
"description": "InstallVersion is the OpenShift installation version string.",
|
|
||||||
"type": "string"
|
|
||||||
},
|
|
||||||
"InstallVersions": {
|
|
||||||
"description": "InstallVersions represents a List of OpenShift installable versions.",
|
|
||||||
"type": "array",
|
|
||||||
"items": {
|
|
||||||
"$ref": "#/definitions/InstallVersion"
|
|
||||||
},
|
|
||||||
"x-ms-identifiers": []
|
|
||||||
},
|
|
||||||
"MachinePool": {
|
"MachinePool": {
|
||||||
"description": "MachinePool represents a MachinePool",
|
"description": "MachinePool represents a MachinePool",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
|
@ -2025,10 +2013,6 @@
|
||||||
"$ref": "#/definitions/IngressProfile"
|
"$ref": "#/definitions/IngressProfile"
|
||||||
},
|
},
|
||||||
"x-ms-identifiers": []
|
"x-ms-identifiers": []
|
||||||
},
|
|
||||||
"installVersion": {
|
|
||||||
"description": "The cluster install version.",
|
|
||||||
"type": "string"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -2052,6 +2036,61 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"OpenShiftVersion": {
|
||||||
|
"description": "OpenShiftVersion represents an OpenShift version that can be installed.",
|
||||||
|
"type": "object",
|
||||||
|
"allOf": [
|
||||||
|
{
|
||||||
|
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ProxyResource"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"properties": {
|
||||||
|
"id": {
|
||||||
|
"description": "The ID for the resource.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"name": {
|
||||||
|
"description": "Name of the resource.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"type": {
|
||||||
|
"description": "The resource type.",
|
||||||
|
"type": "string"
|
||||||
|
},
|
||||||
|
"properties": {
|
||||||
|
"$ref": "#/definitions/OpenShiftVersionProperties",
|
||||||
|
"description": "The properties for the OpenShiftVersion resource."
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"OpenShiftVersionList": {
|
||||||
|
"description": "OpenShiftVersionList represents a List of available versions.",
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"value": {
|
||||||
|
"description": "The List of available versions.",
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"$ref": "#/definitions/OpenShiftVersion"
|
||||||
|
},
|
||||||
|
"x-ms-identifiers": []
|
||||||
|
},
|
||||||
|
"nextLink": {
|
||||||
|
"description": "Next Link to next operation.",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"OpenShiftVersionProperties": {
|
||||||
|
"description": "OpenShiftVersionProperties represents the properties of an OpenShiftVersion.",
|
||||||
|
"type": "object",
|
||||||
|
"properties": {
|
||||||
|
"version": {
|
||||||
|
"description": "Version represents the version to create the cluster at.",
|
||||||
|
"type": "string"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
"Operation": {
|
"Operation": {
|
||||||
"description": "Operation represents an RP operation.",
|
"description": "Operation represents an RP operation.",
|
||||||
"type": "object",
|
"type": "object",
|
||||||
|
|
Загрузка…
Ссылка в новой задаче