Skip to content

Commit

Permalink
add privileged feature to ephemeral too (#1813)
Browse files Browse the repository at this point in the history
  • Loading branch information
aviramha committed Aug 18, 2023
1 parent e6d422e commit 3a14a73
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion changelog.d/1806.added.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
Add option to run agent container as privileged - `"agent" : {"privileged": true}`
Should help with Bottlerocket or other secured k8s environments.
Should help with Bottlerocket or other secured k8s environments.
Applicable for both job/ephemeral.
2 changes: 1 addition & 1 deletion mirrord-schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@
},
"privileged": {
"title": "agent.privileged {#agent-privileged}",
"description": "Run the mirror agent as privileged container. (Not applicable when using ephemeral) Defaults to `false`.\n\nMight be needed in strict environments such as Bottlerocket.",
"description": "Run the mirror agent as privileged container. Defaults to `false`.\n\nMight be needed in strict environments such as Bottlerocket.",
"type": [
"boolean",
"null"
Expand Down
2 changes: 1 addition & 1 deletion mirrord/config/src/agent.rs
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ pub struct AgentConfig {

/// ### agent.privileged {#agent-privileged}
///
/// Run the mirror agent as privileged container. (Not applicable when using ephemeral)
/// Run the mirror agent as privileged container.
/// Defaults to `false`.
///
/// Might be needed in strict environments such as Bottlerocket.
Expand Down
1 change: 1 addition & 0 deletions mirrord/kube/src/api/container.rs
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,7 @@ impl ContainerApi for EphemeralContainer {
"capabilities": {
"add": get_capabilities(agent),
},
"privileged": agent.privileged,
},
"imagePullPolicy": agent.image_pull_policy,
"targetContainerName": runtime_data.container_name,
Expand Down

0 comments on commit 3a14a73

Please sign in to comment.