Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
ci: add containerd PR E2E tests (#3892)
Browse files Browse the repository at this point in the history
  • Loading branch information
jackfrancis authored Oct 6, 2020
1 parent c5d44ed commit 37326bd
Show file tree
Hide file tree
Showing 4 changed files with 43 additions and 16 deletions.
2 changes: 2 additions & 0 deletions .pipelines/e2e-job-template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ jobs:
ENABLE_KMS_ENCRYPTION: ${{ parameters.enableKMSEncryption }}
SUBSCRIPTION_ID: '$(SUBSCRIPTION_ID_E2E_KUBERNETES)'
MSI_USER_ASSIGNED_ID: '$(MSI_USER_ASSIGNED_ID_AKS_ENGINE_E2E)'
CONTAINER_RUNTIME: ${{ parameters.containerRuntime }}
BLOCK_SSH: ${{ parameters.runSSHTests }}

steps:
- template: e2e-step-template.yaml
Expand Down
28 changes: 26 additions & 2 deletions .pipelines/pr-e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,40 @@ jobs:
- template: e2e-job-template.yaml
parameters:
name: 'k8s_1_18_release_e2e'
name: 'k8s_1_18_docker_e2e'
k8sRelease: '1.18'
apimodel: 'examples/e2e-tests/kubernetes/release/default/definition.json'
createVNET: true
enableKMSEncryption: false
containerRuntime: 'docker'
runSSHTests: true

- template: e2e-job-template.yaml
parameters:
name: 'k8s_1_19_release_e2e'
name: 'k8s_1_19_docker_e2e'
k8sRelease: '1.19'
apimodel: 'examples/e2e-tests/kubernetes/release/default/definition.json'
createVNET: true
enableKMSEncryption: false
containerRuntime: 'docker'
runSSHTests: true

- template: e2e-job-template.yaml
parameters:
name: 'k8s_1_18_containerd_e2e'
k8sRelease: '1.18'
apimodel: 'examples/e2e-tests/kubernetes/release/default/definition.json'
createVNET: true
enableKMSEncryption: false
containerRuntime: 'containerd'
runSSHTests: false

- template: e2e-job-template.yaml
parameters:
name: 'k8s_1_19_containerd_e2e'
k8sRelease: '1.19'
apimodel: 'examples/e2e-tests/kubernetes/release/default/definition.json'
createVNET: true
enableKMSEncryption: false
containerRuntime: 'containerd'
runSSHTests: false
13 changes: 2 additions & 11 deletions examples/e2e-tests/kubernetes/release/default/definition.json
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@
"name": "poolwin",
"count": 1,
"vmSize": "Standard_D2s_v3",
"OSDiskSizeGB": 256,
"availabilityProfile": "VirtualMachineScaleSets",
"vnetSubnetId": "/subscriptions/SUB_ID/resourceGroups/RG_NAME/providers/Microsoft.Network/virtualNetworks/VNET_NAME/subnets/SUBNET_NAME",
"osType": "Windows",
"storageProfile": "Ephemeral"
"osType": "Windows"
},
{
"name": "pool1604vhd",
Expand Down Expand Up @@ -121,15 +121,6 @@
"distro": "ubuntu-18.04-gen2",
"availabilityProfile": "VirtualMachineScaleSets",
"vnetSubnetId": "/subscriptions/SUB_ID/resourceGroups/RG_NAME/providers/Microsoft.Network/virtualNetworks/VNET_NAME/subnets/SUBNET_NAME"
},
{
"name": "poolwingen2",
"count": 1,
"vmSize": "Standard_D2s_v3",
"osType": "Windows",
"availabilityProfile": "VirtualMachineScaleSets",
"vnetSubnetId": "/subscriptions/SUB_ID/resourceGroups/RG_NAME/providers/Microsoft.Network/virtualNetworks/VNET_NAME/subnets/SUBNET_NAME",
"osDiskCachingType": "ReadOnly"
}
],
"linuxProfile": {
Expand Down
16 changes: 13 additions & 3 deletions test/e2e/engine/template.go
Original file line number Diff line number Diff line change
Expand Up @@ -231,9 +231,19 @@ func Build(cfg *config.Config, masterSubnetID string, agentSubnetIDs []string, i
}
}

if config.ContainerRuntime == "containerd" &&
prop.OrchestratorProfile.KubernetesConfig.WindowsContainerdURL == "" {
prop.OrchestratorProfile.KubernetesConfig.WindowsContainerdURL = "https://github.com/containerd/containerd/releases/download/v1.4.0/containerd-1.4.0-windows-amd64.tar.gz"
if config.ContainerRuntime == "containerd" {
if prop.OrchestratorProfile.KubernetesConfig.WindowsContainerdURL == "" {
prop.OrchestratorProfile.KubernetesConfig.WindowsContainerdURL = "https://github.com/containerd/containerd/releases/download/v1.4.0/containerd-1.4.0-windows-amd64.tar.gz"
}
if prop.WindowsProfile.WindowsPublisher == "" &&
prop.WindowsProfile.WindowsOffer == "" &&
prop.WindowsProfile.WindowsSku == "" &&
prop.WindowsProfile.ImageVersion == "" {
prop.WindowsProfile.WindowsPublisher = "microsoft-aks"
prop.WindowsProfile.WindowsOffer = "aks-windows"
prop.WindowsProfile.WindowsSku = "2019-datacenter-core-smalldisk-containerd-2005"
prop.WindowsProfile.ImageVersion = "latest"
}
}

if config.ContainerRuntime != "" {
Expand Down

0 comments on commit 37326bd

Please sign in to comment.