Need help to implement some functions using the nexus Integration API

  • How can I Get the members of an existing group repository and Add members to a existing group repository.
  • How can I modify additional properties of a repository. Like:
    - Online status
    - Adding a clean-up policy to the repo
    - Additional remote storage properties of a proxy repo (Check the screenshot attached)

How to configure the security part, I need to implement below tasks:
- add content selectors
- add custom privileges using the content selectors
- add custom roles adding the privileges : guess the addRole() function covers this. > Does this role sync with the a LDAP role?
- add additional privileges or roles to an existing role
- delete content selectors, privileges and roles

My Code: GitHub - atselvan/nexus3-repository-cli: Nexus 3 CLI

Hi Allen,

Take a look at this project:


It has some examples with roles and privileges as well as LDAP leveraging the Integration API. That might be enough to get you going. Let me know if it works out for you.

Cheers,

Nick

1 Like

Hi @nickcook,

Thanks much for your reply. I have already gone through the mentioned repository and the security related functions there did not meet all my needs.

Found this GIST online, A groovy script to create Content Selectors, privileges, and roles programmatically via the Nexus Repository Manager 3 Scripting API. · GitHub - I think this one will help, not sure if it helps completely yet.

Regards,
Allan Selvan