-
Notifications
You must be signed in to change notification settings - Fork 3
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
chech docker image platform when pulling docker image #1166
Conversation
lzy/execution-env/pom.xml
Outdated
<dependency> | ||
<groupId>org.mockito</groupId> | ||
<artifactId>mockito-core</artifactId> | ||
<version>5.11.0</version> |
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.
all versions should be in the parent/pom.xml only
@@ -18,7 +22,9 @@ public record DockerEnvDescription( | |||
List<String> envVars, // In format <NAME>=<value> | |||
@Nullable | |||
String networkMode, | |||
DockerClientConfig dockerClientConfig | |||
DockerClientConfig dockerClientConfig, | |||
@Nonnull |
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.
we don't use any notnull annotations
we considr all fields not null by default, else we mark them as @Nullable
msg = "Pulling image %s done".formatted(image); | ||
LOG.info(msg); | ||
out.log(msg); | ||
} | ||
|
||
private ResultCallback.Adapter<PullResponseItem> pullWithPlatform(String image, @Nullable String platform) | ||
throws InterruptedException { |
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.
{
should be on the next line
} | ||
return null; | ||
}) | ||
) { |
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.
)
should be on line 325
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.
Only ) without { ? I mean
}))
{
...
right?
or
})) {
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.
first case
Check docker image platform when pulling docker image. Allowed platforms passed by DockerEnvDescription#withAllowedPlatforms
empty means all platforms are allowed