Fix AKS errors and warnings
MODIFY
.gitignore
.gitignore
@@ -11,3 +11,4 @@ package-lock.json
Pulumi.*.yaml
.idea/
*.iml
+key.rsa*
\ No newline at end of file

MODIFY
azure-ts-aks-helm/cluster.ts
azure-ts-aks-helm/cluster.ts
// Copyright 2016-2018, Pulumi Corporation. All rights reserved.
import * as azure from "@pulumi/azure";
+import * as azuread from "@pulumi/azuread";
import * as pulumi from "@pulumi/pulumi";
import * as k8s from "@pulumi/kubernetes";
import * as config from "./config";
// Create the AD service principal for the K8s cluster.
-let adApp = new azure.ad.Application("aks");
-let adSp = new azure.ad.ServicePrincipal("aksSp", { applicationId: adApp.applicationId });
-let adSpPassword = new azure.ad.ServicePrincipalPassword("aksSpPassword", {
+let adApp = new azuread.Application("aks");
+let adSp = new azuread.ServicePrincipal("aksSp", { applicationId: adApp.applicationId });
+let adSpPassword = new azuread.ServicePrincipalPassword("aksSpPassword", {
servicePrincipalId: adSp.id,
value: config.password,
endDate: "2099-01-01T00:00:00Z",
@@ -26,9 +27,9 @@ export const k8sCluster = new azure.containerservice.KubernetesCluster("aksClust
dnsPrefix: `${pulumi.getStack()}-kube`,
linuxProfile: {
adminUsername: "aksuser",
- sshKeys: [{
+ sshKey: {
keyData: config.sshPublicKey,
- }],
+ },
},
servicePrincipal: {
clientId: adApp.applicationId,

MODIFY
azure-ts-aks-helm/package.json
azure-ts-aks-helm/package.json
},
"dependencies": {
"@pulumi/azure": "latest",
+ "@pulumi/azuread": "latest",
"@pulumi/kubernetes": "latest",
"@pulumi/pulumi": "latest"
},

MODIFY
azure-ts-aks-mean/cluster.ts
azure-ts-aks-mean/cluster.ts
// Copyright 2016-2018, Pulumi Corporation. All rights reserved.
import * as azure from "@pulumi/azure";
+import * as azuread from "@pulumi/azuread";
import * as pulumi from "@pulumi/pulumi";
import * as k8s from "@pulumi/kubernetes";
import * as config from "./config";
// Create the AD service principal for the K8s cluster.
-let adApp = new azure.ad.Application("aks");
-let adSp = new azure.ad.ServicePrincipal("aksSp", { applicationId: adApp.applicationId });
-let adSpPassword = new azure.ad.ServicePrincipalPassword("aksSpPassword", {
+let adApp = new azuread.Application("aks");
+let adSp = new azuread.ServicePrincipal("aksSp", { applicationId: adApp.applicationId });
+let adSpPassword = new azuread.ServicePrincipalPassword("aksSpPassword", {
servicePrincipalId: adSp.id,
value: config.password,
endDate: "2099-01-01T00:00:00Z",
@@ -26,9 +27,9 @@ export const k8sCluster = new azure.containerservice.KubernetesCluster("aksClust
dnsPrefix: `${pulumi.getStack()}-kube`,
linuxProfile: {
adminUsername: "aksuser",
- sshKeys: [{
+ sshKey: {
keyData: config.sshPublicKey,
- }],
+ },
},
servicePrincipal: {
clientId: adApp.applicationId,

MODIFY
azure-ts-aks-mean/package.json
azure-ts-aks-mean/package.json
},
"dependencies": {
"@pulumi/azure": "latest",
+ "@pulumi/azuread": "latest",
"@pulumi/kubernetes": "latest",
"@pulumi/pulumi": "latest",
"@types/mongoose": "^5.2.11",

MODIFY
azure-ts-aks-multicluster/index.ts
azure-ts-aks-multicluster/index.ts
// Copyright 2016-2018, Pulumi Corporation. All rights reserved.
import * as azure from "@pulumi/azure";
+import * as azuread from "@pulumi/azuread";
import * as pulumi from "@pulumi/pulumi";
import * as config from "./config";
@@ -21,9 +22,9 @@ const aksClusterConfig = [
];
// Create the AD service principal for the K8s cluster.
-const adApp = new azure.ad.Application("aks");
-const adSp = new azure.ad.ServicePrincipal("aksSp", {applicationId: adApp.applicationId});
-const adSpPassword = new azure.ad.ServicePrincipalPassword("aksSpPassword", {
+const adApp = new azuread.Application("aks");
+const adSp = new azuread.ServicePrincipal("aksSp", {applicationId: adApp.applicationId});
+const adSpPassword = new azuread.ServicePrincipalPassword("aksSpPassword", {
servicePrincipalId: adSp.id,
value: config.password,
endDate: "2099-01-01T00:00:00Z",
@@ -36,9 +37,9 @@ const k8sClusters = aksClusterConfig.map((perClusterConfig, index) => {
resourceGroupName: config.resourceGroup.name,
linuxProfile: {
adminUsername: "aksuser",
- sshKeys: [{
+ sshKey: {
keyData: config.sshPublicKey,
- }],
+ },
},
servicePrincipal: {
clientId: adApp.applicationId,

MODIFY
azure-ts-aks-multicluster/package.json
azure-ts-aks-multicluster/package.json
},
"dependencies": {
"@pulumi/azure": "latest",
+ "@pulumi/azuread": "latest",
"@pulumi/kubernetes": "latest",
"@pulumi/pulumi": "latest"
},

Fix AKS errors and warnings (#305)