-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: use custom socket configurations from v1alpha3 #930
Merged
pmengelbert
merged 22 commits into
eraser-dev:main
from
ashnamehrotra:use-custom-socket
Jan 11, 2024
Merged
Changes from 16 commits
Commits
Show all changes
22 commits
Select commit
Hold shift + click to select a range
659efb7
change conversion func addresses from nil to default
ashnamehrotra 6ee356d
handle case of no runtime name and default runtimeSpec in unversioned…
ashnamehrotra 30eec30
remove runtime arg from imagejob, pass runtime name as env var, mount…
ashnamehrotra e22c52c
remove runtime arg and get socketpath based on runtime name in collec…
ashnamehrotra 4871975
change scanner config runtime to runtimespec configuration. use runti…
ashnamehrotra 5b8ac9f
fix api - default runtimeSpec address should be full socket address n…
ashnamehrotra 6ac026b
parse address to get path when setting runtime-sock-volume
ashnamehrotra e79b10b
change approach to use generic CRIPath for all runtimes
ashnamehrotra da3104d
error checks
ashnamehrotra 4e62d5e
update docs
ashnamehrotra a155ab0
testing changes
ashnamehrotra d4c7e71
cleanup and revert testing code
ashnamehrotra 4a0f3f2
move kind config file
ashnamehrotra eae481d
cleanup and e2e test changes
ashnamehrotra 5aefb24
add test that intentionally fails and check that timeout occurs
ashnamehrotra 0e65c00
lint fix CheckImageRemoved ctx should be first arg
ashnamehrotra c92536e
change custom node img to include node version
ashnamehrotra bae74d6
add dockershim to types_test
ashnamehrotra 2d1303e
change NODE_VERSION var to KUBERNETES_VERSION in custom node
ashnamehrotra b802c34
change trivy runtime to os.Getenv(utils.EnvEraserRuntimeName)
ashnamehrotra 5029a1b
fix getRuntimeVar to test for containerd/empty string
ashnamehrotra 8228560
revert CheckImageRemoved and delete failed runtime test
ashnamehrotra File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -160,12 +160,11 @@ func initScanner(userConfig *Config) (Scanner, error) { | |
sugar := logger.Sugar() | ||
trivylogger.Logger = sugar | ||
|
||
runtime := os.Getenv(utils.EnvEraserContainerRuntime) | ||
if runtime == "" { | ||
runtime = utils.RuntimeContainerd | ||
userConfig.Runtime = unversioned.RuntimeSpec{ | ||
Name: unversioned.Runtime(utils.EnvEraserRuntimeName), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This sets |
||
Address: utils.CRIPath, | ||
} | ||
|
||
userConfig.Runtime = runtime | ||
totalTimeout := time.Duration(userConfig.Timeout.Total) | ||
timer := time.NewTimer(totalTimeout) | ||
|
||
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As mentioned below, I would change the name of the build arg to
KUBERNETES_VERSION
. It makes it clearer where the value is ultimately coming from.