Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@haircommander
Copy link
Member

What type of PR is this?

/kind cleanup

What this PR does / why we need it:

As well as update documentation describing how to specify an alternative runtime
And fix some inconsistencies in how the runtime is called in restore.bats

Signed-off-by: Peter Hunt [email protected]

Which issue(s) this PR fixes:

Special notes for your reviewer:

replaces #4099

Does this PR introduce a user-facing change?

none

@openshift-ci-robot openshift-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. labels Aug 19, 2020
@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 19, 2020
@haircommander
Copy link
Member Author

@fgiudici PTAL
the advantage here is we only need to specify
CONTAINER_DEFAULT_RUNTIME=crun and the test takes care of the rest (or also RUNTIME_TYPE if it's vm based)

@codecov
Copy link

codecov bot commented Aug 19, 2020

Codecov Report

Merging #4100 (2ad608e) into master (e54c506) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #4100   +/-   ##
=======================================
  Coverage   40.53%   40.53%           
=======================================
  Files         115      115           
  Lines        9442     9442           
=======================================
  Hits         3827     3827           
  Misses       5182     5182           
  Partials      433      433           

Copy link
Contributor

@fgiudici fgiudici left a comment

Choose a reason for hiding this comment

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

LGTM

test/README.md Outdated
For example, to use [kata](https://github.com/kata-containers/runtime) with shim v2:
```
make localintegration RUNTIME=cc-runtime
make CONTAINER_DEFAULT_RUNTIME=kata RUNTIME_TYPE=vm localintegration
Copy link
Contributor

Choose a reason for hiding this comment

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

The kata shim v2 binary has a slightly cumbersome name ;-)

Suggested change
make CONTAINER_DEFAULT_RUNTIME=kata RUNTIME_TYPE=vm localintegration
make CONTAINER_DEFAULT_RUNTIME=containerd-shim-kata-v2 RUNTIME_TYPE=vm localintegration

Not all tests will work with it (at least for now), but nonetheless we support specifying the RUNTIME_TYPE, so would be good to have this documented.

--runtimes "$RUNTIME_NAME:$RUNTIME_BINARY:$RUNTIME_ROOT:$RUNTIME_TYPE" \
-r "$TESTDIR/crio" \
--runroot "$TESTDIR/crio-run" \
--runtimes "$CONTAINER_RUNTIMES" \
Copy link
Contributor

Choose a reason for hiding this comment

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

If we export CONTAINER_RUNTIMES can we also skip the --runtimes parameter here?

Copy link
Member Author

Choose a reason for hiding this comment

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

I found some weirdness without it, but I forget what that was. Let's try!

RUNTIME_BINARY_PATH=$(command -v $CONTAINER_DEFAULT_RUNTIME || true)
RUNTIME_TYPE=${RUNTIME_TYPE:-oci}
# export here so direct calls to crio later inherit the variable
export CONTAINER_RUNTIMES=${CONTAINER_RUNTIMES:-$CONTAINER_DEFAULT_RUNTIME:$RUNTIME_BINARY_PATH:$RUNTIME_ROOT:$RUNTIME_TYPE}
Copy link
Contributor

Choose a reason for hiding this comment

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

Brilliant!

@haircommander haircommander force-pushed the test-different-runtime branch 2 times, most recently from f462b4e to 607f7e4 Compare August 19, 2020 20:41
Copy link
Member

@giuseppe giuseppe left a comment

Choose a reason for hiding this comment

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

LGTM

/retest

@fidencio
Copy link
Contributor

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Sep 30, 2020
@fidencio
Copy link
Contributor

/retest

1 similar comment
@fidencio
Copy link
Contributor

fidencio commented Oct 8, 2020

/retest

@haircommander haircommander force-pushed the test-different-runtime branch from 9ff287a to 604a666 Compare October 12, 2020 20:13
@openshift-ci-robot openshift-ci-robot removed the lgtm Indicates that a PR is ready to be merged. label Oct 12, 2020
@haircommander
Copy link
Member Author

conflict resolved can I have my tag back

@haircommander
Copy link
Member Author

/retest

@haircommander haircommander force-pushed the test-different-runtime branch 2 times, most recently from bc8aab7 to 7378c4b Compare October 13, 2020 14:45
@haircommander
Copy link
Member Author

/retest

@haircommander
Copy link
Member Author

Kubernetes e2e suite: [sig-network] IngressClass [Feature:Ingress] should set default value on new IngressClass [Serial]
known flake
/retest

@haircommander
Copy link
Member Author

fi
# export here so direct calls to crio later inherit the variable
export CONTAINER_RUNTIMES=${CONTAINER_RUNTIMES:-$CONTAINER_DEFAULT_RUNTIME:$RUNTIME_BINARY_PATH:$RUNTIME_ROOT:$RUNTIME_TYPE}
CONTAINER_UID_MAPPINGS=${CONTAINER_UID_MAPPINGS:-}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Apparently this one is duplicated?

@kolyshkin
Copy link
Collaborator

  1. I think that patches 2 and 4 can be combined into one -- here it does not make sense to add || true and then remove it.

  2. Patch 2 breaks all the tests, as it removes the variable used by them. This might play bad if someone wants to use e.g. git bisect.

so all tests can properly access the runtime root without hardcoding

Signed-off-by: Peter Hunt <[email protected]>
As well as update documentation describing how to specify an alternative runtime
And fix some inconsistencies in how the runtime is called in restore.bats

Signed-off-by: Peter Hunt <[email protected]>
@haircommander
Copy link
Member Author

1. I think that patches 2 and 4 can be combined into one -- here it does not make sense to add `|| true` and then remove it.

2. Patch 2 breaks all the tests, as it removes the variable used by them. This might play bad if someone wants to use e.g. git bisect.

okay, I have implemented point 1. For point 2, I have updated the second commit to not change the variable name in the runtime() function, and update it in the third commit. A git bisect should allow each commit to pass, now

Copy link
Collaborator

@kolyshkin kolyshkin left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@haircommander
Copy link
Member Author

/test kata-containers

@haircommander
Copy link
Member Author

Copy link
Member

@saschagrunert saschagrunert left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Mar 2, 2021
@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: giuseppe, haircommander, kolyshkin, saschagrunert

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

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [giuseppe,haircommander,kolyshkin,saschagrunert]

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

@haircommander
Copy link
Member Author

/retest

@haircommander
Copy link
Member Author

/test kata-containers

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

4 similar comments
@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-ci-robot
Copy link

@haircommander: The following test failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/kata-jenkins 146d47d link /test kata-containers
Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@haircommander
Copy link
Member Author

/override ci/kata-jenkins

@openshift-ci-robot
Copy link

@haircommander: Overrode contexts on behalf of haircommander: ci/kata-jenkins

Details

In response to this:

/override ci/kata-jenkins

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Mar 5, 2021

@haircommander: The following tests failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/openshift-jenkins/integration_crun_cgroupv2 146d47d link /test integration_cgroupv2
ci/prow/e2e-agnostic 146d47d link /test e2e-agnostic
ci/prow/e2e-gcp 146d47d link /test e2e-gcp

Full PR test history. Your PR dashboard.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@haircommander
Copy link
Member Author

/test critest_fedora

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

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. dco-signoff: yes Indicates the PR's author has DCO signed all their commits. lgtm Indicates that a PR is ready to be merged. release-note-none Denotes a PR that doesn't merit a release note.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants