Skip to content
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

Update ContainerProperties to match k8s PodSpec. #478

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

corneil
Copy link
Contributor

@corneil corneil commented Sep 20, 2024

Updated tests to use old and new names.
Deprecated old names.

Fixes #477

Updated tests to use old and new names.
Deprecated old names.

Fixes spring-cloud#477
@onobc onobc added the status/on-hold For various reasons is on hold label Sep 20, 2024
Copy link

@Wordbe Wordbe left a comment

Choose a reason for hiding this comment

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

There are many simple code format adjustments, making it difficult to see the actual changes. However, I appreciate the incorporation of the issues. Thank you.

.withEnv(envVars)
.withEnvFrom(envFromSources)
.withArgs(appArgs)
.withImagePullPolicy(deploymentPropertiesResolver.getImagePullPolicy(deploymentProperties))
Copy link

Choose a reason for hiding this comment

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

👍

@@ -1327,7 +1327,7 @@ public void initContainerFromGlobalProps() {
// Set up a global initContainer (it should be chosen)
KubernetesDeployerProperties.InitContainer globalInitContainerProps = new KubernetesDeployerProperties.InitContainer();
globalInitContainerProps.setContainerName("test-global");
globalInitContainerProps.setImageName("busybox:latest");
globalInitContainerProps.setImage("busybox:latest");
Copy link

Choose a reason for hiding this comment

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

👍

@@ -1327,7 +1327,7 @@ public void initContainerFromGlobalProps() {
// Set up a global initContainer (it should be chosen)
KubernetesDeployerProperties.InitContainer globalInitContainerProps = new KubernetesDeployerProperties.InitContainer();
globalInitContainerProps.setContainerName("test-global");
Copy link

Choose a reason for hiding this comment

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

it would be better to use 'name' instead of 'containerName'

List<String> commands = StringUtils.hasText(commandStr) ? Arrays.asList(commandStr.split(",")) : Collections.emptyList();
String argsStr = PropertyParserUtils.getDeploymentPropertyValue(kubeProps, propertyKey, ".args");
List<String> args = StringUtils.hasText(argsStr) ? Arrays.asList(argsStr.split(",")) : Collections.emptyList();
String envString = PropertyParserUtils.getDeploymentPropertyValue(kubeProps, propertyKey + "environmentVariables");
Copy link

Choose a reason for hiding this comment

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

Would it be difficult to use 'env' instead of 'environmentVariables'?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/on-hold For various reasons is on hold
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Updating initContainers Configuration to Match Pod Specifications
3 participants