Skip to content

Conversation

@dcantah
Copy link
Contributor

@dcantah dcantah commented Mar 8, 2021

  • Add the necessary plumbing in containerd shim to be able to create a job container
    if asked for via the annotation.

Signed-off-by: Daniel Canter [email protected]

@dcantah dcantah requested a review from a team as a code owner March 8, 2021 23:29
@katiewasnothere
Copy link

@dcantah can you rebase to get the new build changes?

@dcantah dcantah force-pushed the job-containers-shim branch from 16de71e to b74108d Compare March 17, 2021 19:02
@dcantah
Copy link
Contributor Author

dcantah commented Mar 17, 2021

@katiewasnothere Donezo

@dcantah dcantah force-pushed the job-containers-shim branch 2 times, most recently from b85da23 to 293d645 Compare April 27, 2021 17:07
@dcantah dcantah force-pushed the job-containers-shim branch from 293d645 to d1890da Compare May 20, 2021 05:18
@dcantah dcantah force-pushed the job-containers-shim branch from d1890da to 3630bb7 Compare May 28, 2021 08:27
@dcantah dcantah force-pushed the job-containers-shim branch 2 times, most recently from 106744f to e2a4265 Compare June 16, 2021 10:58
@dcantah
Copy link
Contributor Author

dcantah commented Jun 16, 2021

Anyone able to give this some eyes @microsoft/containerplat

//
// TODO dcantah: Keep better track of the layers that are added, don't simply discard the SCSI, VSMB, etc. resource types gotten inside.
func MountContainerLayers(ctx context.Context, layerFolders []string, guestRoot string, uvm *uvmpkg.UtilityVM) (_ string, err error) {
func MountContainerLayers(ctx context.Context, layerFolders []string, guestRoot, volumeMountPath string, uvm *uvmpkg.UtilityVM) (_ string, err error) {

Choose a reason for hiding this comment

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

nit: IMO "volumeMountPath" is not a very clear name for what this is

Copy link

@katiewasnothere katiewasnothere left a comment

Choose a reason for hiding this comment

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

few comments, otherwise looks fine to me

* Add the necessary plumbing in containerd shim to be able to create a job container
if asked for via the annotation.

* Rework jobcontainers package a bit to return a resources struct to avoid some hacks during cleanup.
This was resource cleanup for wcow/lcow is the exact same for job containers in the shim.

* Change some of the layer code to handle taking in a volume mount point

Signed-off-by: Daniel Canter <[email protected]>
@dcantah dcantah force-pushed the job-containers-shim branch from 5982e53 to bbf5589 Compare June 23, 2021 03:28
Copy link
Contributor

@anmaxvl anmaxvl left a comment

Choose a reason for hiding this comment

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

do you need to revendor test directory here? do we have tests (which can be added later if not)?

@dcantah
Copy link
Contributor Author

dcantah commented Jun 25, 2021

@anmaxvl
Copy link
Contributor

anmaxvl commented Jun 25, 2021

@anmaxvl Tests have been in for awhile, they just won't work without this PR :P https://github.com/microsoft/hcsshim/blob/master/test/cri-containerd/jobcontainer_test.go

oh right. I noticed that hcsshim vendored in the test folder was out of date when I reading through your branch locally. can you make sure that it's up to date?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants