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

documentation: polish NB contract and add more comments #4274

Merged
merged 9 commits into from
Apr 11, 2024
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pkg/parser/utilities.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ func getBaseTemplate() *nbcontractv1.Configuration {
CustomKubeBinaryUrl: "https://acs-mirror.azureedge.net/kubernetes/v1.26.0/binaries/kubernetes-node-linux-amd64.tar.gz",
PrivateKubeBinaryUrl: "",
},
KubeproxyUrl: "",
KubeProxyUrl: "",
EnableSsh: true,
}
}
Expand Down
4 changes: 3 additions & 1 deletion pkg/proto/nbcontract/v1/apiserverconfig.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 6 additions & 3 deletions pkg/proto/nbcontract/v1/apiserverconfig.proto
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ syntax = "proto3";
package nbcontract.v1;

message ApiServerConfig {
string api_server_public_key = 1;
string api_server_name = 2;
}
// The certificate public key of the API server.
string api_server_public_key = 1;

// The name or endpoint URI of the API server.
string api_server_name = 2;
}
21 changes: 14 additions & 7 deletions pkg/proto/nbcontract/v1/authconfig.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

23 changes: 18 additions & 5 deletions pkg/proto/nbcontract/v1/authconfig.proto
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,24 @@ package nbcontract.v1;

// Auth Config fields stored in azure.json used by cloud-provider-azure
message AuthConfig {
string target_cloud = 1; // set to cloud, default to AzurePublicCloud
// Target cloud. Set to cloud. Default to AzurePublicCloud
string target_cloud = 1;

// Tenant ID
string tenant_id = 2;

// Subscription ID
string subscription_id = 3;
string service_principal_id = 4; // set to aadClientId
string service_principal_secret = 5; // set to aadClientSecret
string assigned_identity_id = 6; //could be user or system assigned, depending on the type
bool use_managed_identity_extension = 7; // default to false

// Service Principal ID. set to aadClientId
string service_principal_id = 4;

// Service Principal Secret. set to aadClientSecret
string service_principal_secret = 5;

// Assigned identity id, could be user or system assigned, depending on the type.
string assigned_identity_id = 6;

// Specify if use managed identity extension, default to false
bool use_managed_identity_extension = 7;
}
47 changes: 32 additions & 15 deletions pkg/proto/nbcontract/v1/clusterconfig.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

39 changes: 35 additions & 4 deletions pkg/proto/nbcontract/v1/clusterconfig.proto
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,28 @@ package nbcontract.v1;

// Cluster Config fields stored in azure.json used by cloud-provider-azure
message ClusterConfig {
// Rescource group name
string resource_group = 1;

// Location
string location = 2;

// VM type
VM vm_type = 3; // default to standard for v1.27 and below versions and vmss for v1.28+ versions

// Primary availability set name
string primary_availability_set = 4;

// Primary scale set name
string primary_scale_set = 5;

// Cluster network config
ClusterNetworkConfig virtual_network_config = 6;

// Specifiy if it uses instance metadata
bool use_instance_metadata = 7; // default to false

// Load balancer config
LoadBalancerConfig load_balancer_config = 8;

enum VM {
Expand All @@ -20,18 +35,34 @@ message ClusterConfig {
}

message ClusterNetworkConfig {
// Virtual network name
string vnet_name = 1;

// Virtual network resource group
string vnet_resource_group = 2;

// Subnet name
string subnet = 3;

// Network security group name
string security_group_name = 4;

// Route table name
string route_table = 5;
}

message LoadBalancerConfig {
LoadBalancerSku load_balancer_sku = 1; // default to basic
optional bool exclude_master_from_standard_load_balancer = 2; // default to true
optional int32 max_load_balancer_rule_count = 3; // default to 148
optional bool disable_outbound_snat = 4; // default to false
// Load balancer sku, default to basic
LoadBalancerSku load_balancer_sku = 1;

// Specify if master node should be excluded from standard load balancer, default to true
optional bool exclude_master_from_standard_load_balancer = 2;

// Maximum number of load balancer rules, default to 148
optional int32 max_load_balancer_rule_count = 3;

// Disable outbound SNAT (Source Network Address Translation) for load balancer, default to false
optional bool disable_outbound_snat = 4;

enum LoadBalancerSku {
UNSPECIFIED = 0;
Expand Down
Loading
Loading