Skip to content

Commit 1cd7740

Browse files
committed
[IMDS Lockdown] Add example of usage to imds-access.sh helper.
1 parent d6ed357 commit 1cd7740

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

cookbooks/aws-parallelcluster-environment/files/imds/imds-access.sh

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,24 @@ function help() {
3232
--unset <user1,...,userN> Remove iptables rules related to IMDS for the given list of users
3333
--flush Restore default IMDS access
3434
--help Print this help message
35+
36+
Examples:
37+
38+
Allow access for USER1 and USER2, without changing other users
39+
${cmd} --allow USER1,USER2
40+
41+
Deny access for USER1 and USER2, without changing other users
42+
${cmd} --deny USER1,USER2
43+
44+
Allow access only for USER1 and USER2, removing every other user from the allowlist
45+
${cmd} --flush
46+
${cmd} --allow USER1,USER2
47+
48+
Remove rules for USER1 and USER2, without changing other users
49+
${cmd} --unset USER1,USER2
50+
51+
Remove IMDS lockdown, so that all users will be able to access IMDS
52+
${cmd} --flush
3553
EOF
3654
}
3755

0 commit comments

Comments
 (0)