Staged software releases in Nexus Professional are the best way to enable your development team to push a release to an artifact repository such as Nexus while providing management and quality assurance with a way to test and approve a release before "burning" it to production.

How to configure staging repositories

First step, is to download Nexus Professional if you don't already have it installed. Once you've downloaded Nexus, log in as an administrator, in order to be able to perform the following configuration:

  1. From Nexus, click on the "Repositories" link in left navigation.
  2. Click on the repository you want to use, or create one (If you need help with that take a look at the Nexus book, here)
  3. Click on the "Configuration" tab.
  4. Set the "Allow Deployment" field to false.
  5. Click the Save button.

edit repository screen shot

Done! Now users will not be able to deploy or upload artifacts directly to the repository. All artifacts must be staged and promoted to this repository. For more information on staging and promoting take a look at this, or with the maven plugin, here.

To create a staging repository:

  1. From Nexus, click on the "Staging" link in left navigation.
  2. Click the "Add" button then the "Staging Profile" item.
  3. Enter the following information:
    • Profile Name: Staging Demo Profile
    • Profile Repository Target: All (Maven2)
    • Staging Repository ID Template: staging-demo
    • Staging Repository Name Template: Staging Demo
    • Staging Repository Template: Default Release Hosted Repository Template
    • Target Groups: Public Releases
  4. Click the "Save" button

create staging repo

A new role is created for each staging profile that is created to manage user permissions. In this example we'll use the role "Staging Deployer: (Staging Demo Profile)".

Assign the new role to your users. You can find more details on user management, here.

assign staging role