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

feat: Windows containerd VHD support #4137

Merged
merged 9 commits into from
Apr 12, 2021

Conversation

marosset
Copy link
Contributor

@marosset marosset commented Dec 18, 2020

Reason for Change:

Issue Fixed:

Credit Where Due:

Does this change contain code from or inspired by another project?

  • No
  • Yes

If "Yes," did you notify that project's maintainers and provide attribution?

  • No
  • Yes

Requirements:

Notes:

@marosset
Copy link
Contributor Author

I still need to address logic in cmd/upgrade.go

@codecov
Copy link

codecov bot commented Dec 18, 2020

Codecov Report

Merging #4137 (6ad2f1f) into master (47c439d) will decrease coverage by 0.01%.
The diff coverage is 84.37%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #4137      +/-   ##
==========================================
- Coverage   72.07%   72.05%   -0.02%     
==========================================
  Files         141      141              
  Lines       21640    21642       +2     
==========================================
- Hits        15596    15595       -1     
- Misses       5093     5096       +3     
  Partials      951      951              
Impacted Files Coverage Δ
cmd/upgrade.go 35.92% <0.00%> (-0.54%) ⬇️
pkg/api/defaults.go 93.44% <100.00%> (-0.02%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 47c439d...6ad2f1f. Read the comment docs.

@marosset
Copy link
Contributor Author

marosset commented Jan 5, 2021

@jsturtevant this should be ready for review

@marosset marosset changed the title [WIP] - feat: Windows containerd VHD support feat: Windows containerd VHD support Jan 5, 2021
cmd/upgrade.go Outdated Show resolved Hide resolved
}
if windowsProfile.WindowsOffer == "" {
windowsProfile.WindowsOffer = AKSWindowsServer2019OSImageConfig.ImageOffer
windowsProfile.WindowsOffer = defaultImageConfig.ImageOffer
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this seems like it could get into a bad state if the profile for the windows publisher doesn't not equal defaultimageconfig. Would it be simpler to calculate the default config based on profile (which seems to be happening partially above) and then update accordingly?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are many different offers available to users that we do not curate in aks-engine (1909, 2004, 20H2 images, etc).
I don't think it is possible for us to maintain default values for all of these offers.

I agree users can get into a bad state if they only specify windowsPublisher but am not sure what else to do here.
If things get messed up ARM does have a detailed message saying the publisher/offer/sku/image cannot be found.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we can nest these and only set offer if windowsPublisher == defaultImageConfig.ImagePublisher?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense on all the versions. If we assume they can get into a bad state could this logic be simplified and spit out a warning or maybe even an error that that tells they are going to get into a bad state with the values provided if they don't use one of our known defaults?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we can nest these and only set offer if windowsPublisher == defaultImageConfig.ImagePublisher?

for some reason this last comment didn't show up in my ui but I think we were thinking in the same direction

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea. I'll check if we think things are not good, use the default image, a log a warming.

Copy link
Member

@jackfrancis jackfrancis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's remove the containerd-specific WindowsProfile default stuff here that we do to support E2E tests now that these defaults have matriculated to the actual api model defaults flow:

https://github.com/Azure/aks-engine/blob/master/test/e2e/engine/template.go#L253

@olljanat
Copy link

@marosset I wonder that is plan actually also drop Docker from those containerd images as old comment on code proposes it already?

# TODO: make decision on if we want to install docker along with containerd (will need to update CSE too,)
Install-Docker
if ($containerRuntime -eq 'containerd') {
Install-ContainerD
}

@marosset marosset force-pushed the win-containerd-image-config branch from 5bbdbfd to a223f75 Compare March 31, 2021 19:44
@jsturtevant
Copy link
Contributor

/lgtm

@jackfrancis did your requested changes get addressed?

@jackfrancis
Copy link
Member

@jsturtevant yep!

@acs-bot
Copy link

acs-bot commented Apr 12, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jsturtevant, marosset

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [jsturtevant,marosset]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@jsturtevant jsturtevant dismissed jackfrancis’s stale review April 12, 2021 20:18

comments were addressed

@jsturtevant jsturtevant merged commit 3445c1b into Azure:master Apr 12, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants