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

feat: security context #455

Merged
merged 15 commits into from
Mar 17, 2022
Merged

feat: security context #455

merged 15 commits into from
Mar 17, 2022

Conversation

iliapolo
Copy link
Member

@iliapolo iliapolo commented Mar 16, 2022

SecurityContext for pods and containers. I included only the properties that I thought were most common and that I could quickly understand. If we see the need to add additional ones, we'll do that at a later time.

The default values correspond to the values applied by Kubernetes if the property is not specified.

Fixes #348

Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
@iliapolo iliapolo requested a review from Chriscbr March 16, 2022 09:19
@iliapolo
Copy link
Member Author

@Chriscbr Even though PodSecurityContext and ContainerSecurityContext share some common properties, I intentionally didn't create a common interface/class since it felt the coupling is not worth it compared to the small duplication.

Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
@Chriscbr Chriscbr added the pr/do-not-merge Do not auto merge the PR label Mar 16, 2022
Copy link
Contributor

@Chriscbr Chriscbr left a comment

Choose a reason for hiding this comment

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

This looks great @iliapolo ! 😄 I'll approve this with do-not-merge so you can look at the comments and address them as you see fit.

src/container.ts Show resolved Hide resolved
src/pod.ts Outdated Show resolved Hide resolved
src/pod.ts Show resolved Hide resolved
test/pod.test.ts Show resolved Hide resolved
src/pod.ts Show resolved Hide resolved
src/pod.ts Outdated Show resolved Hide resolved
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: iliapolo <epolon@amazon.com>
@iliapolo iliapolo removed the pr/do-not-merge Do not auto merge the PR label Mar 17, 2022
iliapolo and others added 2 commits March 17, 2022 20:37
Signed-off-by: iliapolo <epolon@amazon.com>
Signed-off-by: github-actions <github-actions@github.com>
@mergify mergify bot merged commit 963e0b6 into k8s-22/main Mar 17, 2022
@mergify mergify bot deleted the epolon/security-context branch March 17, 2022 18:43
iliapolo added a commit that referenced this pull request Apr 13, 2022
`SecurityContext` for pods and containers. I included only the properties that I thought were most common and that I could quickly understand. If we see the need to add additional ones, we'll do that at a later time.

The default values correspond to the values applied by Kubernetes if the property is not specified.

Fixes #348

(cherry picked from commit 963e0b6)
Signed-off-by: Eli Polonsky <epolon@amazon.com>

# Conflicts:
#	docs/java.md
#	docs/python.md
#	docs/typescript.md
#	src/deployment.ts
@iliapolo
Copy link
Member Author

💚 All backports created successfully

Status Branch Result
k8s-21/main

Questions ?

Please refer to the Backport tool documentation

iliapolo added a commit that referenced this pull request Apr 13, 2022
`SecurityContext` for pods and containers. I included only the properties that I thought were most common and that I could quickly understand. If we see the need to add additional ones, we'll do that at a later time.

The default values correspond to the values applied by Kubernetes if the property is not specified.

Fixes #348

(cherry picked from commit 963e0b6)
Signed-off-by: Eli Polonsky <epolon@amazon.com>

# Conflicts:
#	docs/java.md
#	docs/python.md
#	docs/typescript.md
#	src/deployment.ts
iliapolo added a commit that referenced this pull request Apr 13, 2022
`SecurityContext` for pods and containers. I included only the properties that I thought were most common and that I could quickly understand. If we see the need to add additional ones, we'll do that at a later time.

The default values correspond to the values applied by Kubernetes if the property is not specified.

Fixes #348

(cherry picked from commit 963e0b6)
Signed-off-by: Eli Polonsky <epolon@amazon.com>

# Conflicts:
#	docs/java.md
#	docs/python.md
#	docs/typescript.md
#	src/deployment.ts
@iliapolo
Copy link
Member Author

💚 All backports created successfully

Status Branch Result
k8s-20/main

Questions ?

Please refer to the Backport tool documentation

iliapolo added a commit that referenced this pull request Apr 13, 2022
`SecurityContext` for pods and containers. I included only the properties that I thought were most common and that I could quickly understand. If we see the need to add additional ones, we'll do that at a later time.

The default values correspond to the values applied by Kubernetes if the property is not specified.

Fixes #348

(cherry picked from commit 963e0b6)
Signed-off-by: Eli Polonsky <epolon@amazon.com>

# Conflicts:
#	docs/java.md
#	docs/python.md
#	docs/typescript.md
#	src/deployment.ts
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.

Configure the security context of containers and pods
2 participants