Class RequiredGrants
java.lang.Object
io.jenkins.plugins.namespacecloud.client.RequiredGrants
The Namespace permissions this plugin needs, and the
nsc token create
invocation that mints a token carrying exactly those grants.
Resource types and actions are those documented at namespace.so/docs/security/permissions. Keeping the list here (rather than scattered across call sites) means the configuration page can show the operator a copy-pasteable command.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA singleresource_typeplus the actions needed on it. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final List<RequiredGrants.Grant> Grants needed to provision, observe and tear down agents.static final List<RequiredGrants.Grant> Additional grants only the SSH launch strategy needs. -
Method Summary
Modifier and TypeMethodDescriptionstatic String"instance: create, get, list"— for display.static List<RequiredGrants.Grant> forConfiguration(boolean anyTemplateUsesSsh) All grants that apply, given whether any template uses the SSH launcher.static List<RequiredGrants.Grant> mergeByResourceType(List<RequiredGrants.Grant> grants) Collapses grants that share a resource type, soinstanceappears once with the union of its actions rather than twice.static StringnscCommand(boolean anyTemplateUsesSsh) Renders annsc token createcommand that mints a token with these grants.
-
Field Details
-
CORE
Grants needed to provision, observe and tear down agents. -
SSH_ONLY
Additional grants only the SSH launch strategy needs.
-
-
Method Details
-
forConfiguration
All grants that apply, given whether any template uses the SSH launcher. -
nscCommand
Renders annsc token createcommand that mints a token with these grants. Shown on the configuration page so the operator does not have to assemble the JSON by hand. -
mergeByResourceType
Collapses grants that share a resource type, soinstanceappears once with the union of its actions rather than twice. -
describe
"instance: create, get, list"— for display.
-