-
Notifications
You must be signed in to change notification settings - Fork 241
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Workaround for AWS pod identity and non-root programs
AWS pod identity creates a token with `0600` permissions and `root:root`: ``` -rw------- 1 root root 1498 Aug 13 12:47 /run/secrets/eks.amazonaws.com/serviceaccount/..2020_08_13_12_47_11.793276204/token ``` This prevents programs running inside containers using a non-root account to read the token. See [1] for details. This CR working around that by adding ``` securityContext: fsGroup: 33 ``` into the pod spec. After that the token is owned by the given group and has `0640` permissions: ``` -rw-r----- 1 root www-data 1498 Aug 13 14:20 /run/secrets/eks.amazonaws.com/serviceaccount/..2020_08_13_14_20_31.793276204/token ``` The id of the group can be changed via the `fs_group` service parameter. [1] aws/amazon-eks-pod-identity-webhook#8
- Loading branch information
Showing
3 changed files
with
24 additions
and
0 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -539,6 +539,9 @@ | |
"aws" | ||
] | ||
}, | ||
"fs_group": { | ||
"type": "int" | ||
}, | ||
"healthcheck_mode": { | ||
"enum": [ | ||
"cmd", | ||
|
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