Last active
August 29, 2015 14:27
-
-
Save dustinmm80/a6451cc72130089ab222 to your computer and use it in GitHub Desktop.
Example of grouping variables in a Conjur policy
This file contains hidden or 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
# List of created variables | |
dev_variables = [...] | |
# Creating a role of type 'variable_group' with name 'dev-variables' | |
dev_variables_group = role 'variable_group', 'dev-variables' | |
# Allow that role to execute the variables | |
dev_variables.each do |v| | |
v.permit 'execute', dev_variables_group | |
end | |
# dev group and layer | |
dev_group = group 'dev-users' | |
dev_layer = layer 'dev-bots' | |
# Grant the 'dev_variables_group' role to the group and layer, so they assume its permissions | |
dev_variables_group.grant_to dev_group | |
dev_variables_group.grant_to dev_layer |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment