Repository Management with Nexus
Repository Management with Nexus

Repository Management with Nexus

Sonatype, Inc. ()
Sonatype, Inc. ()
, Tim O'Brien ()
, Jason Van Zyl ()
, Damian Bradicich ()
, John Casey ()
, Tamás Cservenák ()
, Brian Demers ()
, Brian Fox ()
, Marvin Froeder ()
, Anders Hammar ()
, Rich Seddon ()
, Juven Xu ()

Abstract

Nexus manages software “artifacts” required for development, deployment, and provisioning. If you develop software, Nexus can help you share those artifacts with other developers and end-users. Maven’s central repository has always served as a great convenience for users of Maven, but it has always been recommended to maintain your own repositories to ensure stability within your organization. Nexus greatly simplifies the maintenance of your own internal repositories and access to external repositories. With Nexus you can completely control access to, and deployment of, every artifact in your organization from a single location.


1. Introducing Sonatype Nexus
1.1. Introduction
1.2. Nexus Open Source
1.3. Nexus Professional
1.4. Choosing a Nexus Edition
1.5. History of Nexus
2. Repository Management
2.1. Repository Management
2.2. What is a Repository?
2.3. What is a Repository Manager
2.4. Reasons to Use a Repository Manager
2.5. Adopting a Repository Manager
3. Installing and Running Nexus
3.1. Downloading Nexus
3.2. Installing Nexus
3.3. Upgrading Nexus
3.4. Running Nexus
3.5. Post-Install Checklist
3.6. Configuring Nexus as a Service
3.7. Running Nexus Behind a Proxy
3.8. Installing the Nexus WAR
3.9. Installing a Nexus Professional License
3.10. Sonatype Nexus Directories
4. Configuring Maven to Use Nexus
4.1. Introduction
4.2. Configuring Maven to Use a Single Nexus Group
4.3. Adding Custom Repositories for Missing Dependencies
4.4. Adding a New Repository
4.5. Adding a Repository to a Group
5. Using Nexus
5.1. Introduction
5.2. Browsing Repositories
5.3. Browsing Groups
5.4. Searching for Artifacts
5.5. Uploading Artifacts
5.6. Browsing System Feeds
5.7. Log Files and Configuration
5.8. Changing Your Password
5.9. Filing a Problem Report
6. Configuring Nexus
6.1. Configuring Nexus
6.2. Customizing Server Configuration
6.3. Configuring Automated Error Reporting Settings
6.4. New Version Notification
6.5. Managing Repositories
6.6. Managing Groups
6.7. Managing Routes
6.8. Managing Scheduled Tasks
6.9. Managing Security
6.10. Managing Privileges
6.11. Managing Repository Targets
6.12. Managing Security Roles
6.13. Managing Users
6.14. Network Configuration
6.15. Nexus Logging Configuration
6.16. Managing Nexus Plugins
7. Nexus LDAP Integration
7.1. Enabling the LDAP Authentication Realm
7.2. Configuring Nexus LDAP Integration
7.3. Connection and Authentication
7.4. User and Group Mapping
7.5. Mapping Users and Groups with Active Directory
7.6. Mapping Users and Groups with posixAccount
7.7. Mapping Roles to LDAP Users
7.8. Mapping Nexus Roles for External Users
7.9. Mapping External Roles to Nexus Roles
7.10. Enterprise LDAP Support
8. Nexus Procurement Suite
8.1. Introduction
8.2. The Stages of Procurement
8.3. Two Approaches to Procurement
8.4. Procured Development Repository
8.5. Installing the Procurement Suite
8.6. Setting up a Procured Repository
8.7. Enable Remote Index Downloads
8.8. Create a Hosted Repository
8.9. Configuring Procurement for Hosted Repository
8.10. Procured Repository Administration
8.11. Viewing the Procurement Management Interface
8.12. Configuring a Procurement Rule
8.13. Managing Procurement Rules
8.14. Stopping Procurement
9. Build Promotion with the Nexus Staging Suite
9.1. Introduction
9.2. Releasing Software with a Staging Repository
9.3. How the Staging Suite Works
9.4. Multi-level Staging and Build Promotion
9.5. Using the Nexus Staging Suite
9.6. Configuring Staging Profiles
9.7. Configuring a Repository Target
9.8. Configuring Staging Profiles
9.9. Configuring Build Promotion Profiles
9.10. Adding the Staging Deployer Role
9.11. Performing a Staged Deployment with Maven
9.12. Creating a New Project
9.13. Update the POM: Deployment Configuration
9.14. Update settings.xml with Deployment Credentials
9.15. Deploying to a Staged Repository
9.16. Uploading a Staged Deployment in Nexus
9.17. Managing Rulesets
9.18. Managing Staging Rulesets
9.19. Defining Rulesets for Promotion
9.20. Managing Staging Repositories in Nexus
9.21. Closing an Open Repository
9.22. Using the Staging Repository
9.23. Releasing a Staging Repository
9.24. Promoting a Staging Repository
9.25. Releasing, Promoting, and Dropping Build Promotion Profiles
9.26. Managing Staging Repositories with the Nexus Maven Plugin
9.27. Running the Nexus Maven Plugin
9.28. Configuring Nexus Maven Plugin for Staging
10. Managing Maven Settings
10.1. Introduction
10.2. Manage Maven Settings Templates
10.3. Downloading Maven Settings with the Nexus Maven Plugin
11. OSGi Bundle Repositories
11.1. Introduction
11.2. Managing OSGi Bundle Repositories
11.3. Proxy OSGi Bundle Repositories
11.4. Hosted OSGi Bundle Repositories
11.5. Virtual OSGi Bundle Repositories
11.6. Grouping OSGi Bundle Repositories
12. P2 Repositories
12.1. Introduction
13. Deploying Sites to Nexus
13.1. Introduction
14. User Account Plugin
14.1. Installing the User Account Plugin
14.2. Configuring the User Account Plugin
14.3. Signing Up for an Account
14.4. Manual Activation of New Users
14.5. Modifying Default User Permissions
15. Nexus Atlassian Crowd Plugin
15.1. Installing the Crowd Plugin
15.2. Configuring the Crowd Plugin
15.3. Crowd Access Settings
15.4. Adding the Crowd Authentication Realm
15.5. Configuring a Nexus Application in Crowd
15.6. Mapping Crowd Groups to Nexus Roles
15.7. Adding a Crowd Role to a Nexus User
16. Artifact Bundles
16.1. Creating an Artifact Bundle from a Maven Project
16.2. Uploading an Artifact Bundle to Nexus
17. Nexus Best Practices
17.1. Introduction
17.2. Repositories per Project/Team
17.3. Partition Shared Repositories
18. Developing Nexus Plugins
18.1. Nexus Plugins
18.2. Nexus Extension Points
18.3. Nexus Plugin Extension Points
18.4. Nexus Plugin Extension
18.5. Nexus Index HTML Customizer
18.6. Static Plugin Resources
18.7. Plugin Templates
18.8. Event Inspectors
18.9. Content Generators
18.10. Content Classes
18.11. Storage Implementations
18.12. Repository Customization
18.13. Item and File Inspectors
18.14. Nexus Feeds
18.15. Nexus Tasks and Task Configuration
18.16. Application Customization
18.17. Request Processing
18.18. Using the Nexus Plugin Archetype
18.19. Set the Target Nexus Version
18.20. Building a Nexus Plugin Project
18.21. Creating a Complex Plugin
18.22. Nexus Plugin Descriptor Maven Plugin
18.23. The Nexus Plugin Descriptor
18.24. Defining Custom Repository Types
A. Migrating to Nexus from Artifactory
A.1. Introduction
A.2. Creating an Artifactory Backup
A.3. Installation of the Migration Plugin and Artifactory Bridge
A.4. Importing an Artifactory System Backup
A.5. Configuring the Artifactory Import
A.6. Configuring Artifactory Group Imports
A.7. Configuring Artifactory Repository Imports
A.8. Configuring Users and Privileges in the Artifactory Import
A.9. Performing the Artifactory Import
A.10. Configuring Artifactory Clients to Use Nexus
B. Migrating to Nexus from Archiva
B.1. Introduction
B.2. Migrating Archiva Repositories
B.3. Migrating an Archiva Managed Repository
B.4. Migrating an Archiva Proxy Connector
C. Configuring Nexus for SSL
C.1. Introduction
C.2. Importing a SSL Client Certificate
C.3. Configuring Nexus to Serve SSL
C.4. Redirecting Non-SSL Connections to SSL
D. Contributing to the Nexus Book
D.1. Contributor License Agreement (CLA)
D.2. Contributors, Authors, and Editors
D.3. Tools Used to Build and Write this Book
D.4. How to Build the Book
D.5. Subscribing to the Book Developers List
E. Copyright
F. Creative Commons License
F.1. Creative Commons BY-NC-ND 3.0 US License
F.2. Creative Commons Notice

List of Figures

3.1. Downloading Nexus Open Source from nexus.sonatype.org
3.2. Selecting the Nexus Open Source Distribution Download
3.3. Default Nexus Administrative Credentials (admin/admin123)
3.4. Nexus Application Window (default login/password is admin/admin123)
3.5. Script Directory for 32-bit GNU/Linux
3.6. Nexus Professional Licensing Panel
3.7. Nexus Professional End-user License Agreement
3.8. License Upload Finished Dialog
3.9. Uninstall License Confirmation Dialog
3.10. License Uninstall Completed Dialog
3.11. The Sonatype Nexus Work Directory
3.12. Nexus Professional Configuration Directory
4.1. Creating a New Nexus Proxy Repository
4.2. Adding a Nexus Repository
4.3. Adding New Repositories to a Nexus Group
5.1. Nexus Interface for Anonymous Users
5.2. Browsing a Nexus Repository
5.3. Browsing a Nexus Repository Index
5.4. View an Artifact’s Dependencies
5.5. Viewing Artifact Metadata
5.6. Editing Artifact Metadata
5.7. Browsing a Nexus Group
5.8. Browsing a Nexus Group Index
5.9. Results of an Artifact Search for "guice"
5.10. Configuring Nexus as an OpenSearch Provider
5.11. OpenSearch Search Results in Nexus
5.12. Nexus Available as an Option in the Firefox OpenSearch Provider List
5.13. Searching Artifact Metadata
5.14. Metadata Search Results for Custom Metadata
5.15. Metadata Search Results for Custom Metadata
5.16. Artifact Upload Form
5.17. Browsing Nexus System Feeds
5.18. Browsing Nexus Logs and Configuration
5.19. Selecting the Update Frequency when Tailing a Log File
5.20. Changing Your Nexus Password
5.21. Generating a Nexus Problem Report
6.1. Nexus Server Configuration (File, SMTP, and HTTP Config)
6.2. Nexus Server Configuration (Security Settings, Anonymous Access)
6.3. Nexus Server Configuration (App Server and HTTP Proxy Config)
6.4. Configuring PGP Key server Preferences
6.5. Configuring the Automated Error Reporting
6.6. Sonatype Issue Tracker
6.7. Signing Up for a Sonatype Issue Tracker Account
6.8. New Version Notification Settings
6.9. Repository Configuration Screen for a Proxy Repository
6.10. Repository Configuration Screen for a Proxy Repository
6.11. Proxy Configuration Access Settings for a Hosted Repository
6.12. Configuring Mirrors for Proxy Repositories
6.13. Configuring Mirrors for a Hosted Repository
6.14. Repository Summary Panel for a Hosted Repository
6.15. Repository Summary Panel for a Proxy Repository
6.16. Repository Summary Panel for a Virtual Repository
6.17. Configuring Remote Repository Auto Block/Unblock
6.18. Group Configuration Screen in Nexus
6.19. Routes Configuration Screen in Nexus
6.20. Managing Nexus Scheduled Tasks
6.21. Configuring a Scheduled Backup of Nexus Configuration
6.22. Managing Security Privileges
6.23. Managing Security Privileges
6.24. Create, Delete, Read, and Update Privileges Created
6.25. Managing Repository Targets
6.26. Managing Repository Targets
6.27. Managing Security Roles
6.28. Managing Security Roles
6.29. Managing Security Roles
6.30. Managing Security Roles
6.31. Managing Users
6.32. Nexus User Role Tree
6.33. Nexus User Privilege Trace
6.34. The Log Configuration Panel
6.35. Administrative Menu Link for the Plugin Console
6.36. Nexus Plugin Console
6.37. Nexus Plugin Console Displaying REST endpoints for a Plugin
7.1. Adding the LDAP Authentication Realm to Available Realms
7.2. Move the LDAP Authentication Realm to the Top of Selected
7.3. LDAP Configuration Option in the Nexus Menu
7.4. Configuring Nexus LDAP for Active Directory
7.5. Checking the User and Group Mapping in LDAP Configuration
7.6. Viewing All Configured Users
7.7. All Default Realm Users
7.8. All LDAP Users
7.9. Search LDAP Users
7.10. Mapping the Deployment Role to an External User
7.11. Selecting External Role Mapping in the Role Management Panel
7.12. Selecting an Externally Managed Role to Map to a Nexus Role
7.13. Mapping an External Role to a Nexus Role
7.14. Defining Multiple LDAP Servers in Nexus Professional
7.15. Use Multiple LDAP Servers in a Fail-over Scenario
7.16. Supporting Multiple LDAP Schemas with Nexus Professional
7.17. Setting the LDAP Query Cache Duration (in Seconds)
7.18. Setting the LDAP Connection Timeout (in Seconds)
7.19. Using User & Group Mapping Templates
7.20. Testing a User Login
7.21. Supply a User’s Login Credentials
8.1. Procurement to a Certified Release Repository
8.2. Procurement to a Certified Development Repository
8.3. Artifact Procurement in the Nexus Menu
8.4. Enabling Remote Index Downloads for a Proxy Repository
8.5. Verification that the Remote Index has been Downloaded
8.6. Adding a Hosted Repository
8.7. Adding the "Secured" Hosted Repository
8.8. Adding a Procured Repository
8.9. Configuring Procurement for a Hosted Repository
8.10. Hosted Repository is a Proxy Repository while Procurement is Active
8.11. Viewing a Repository in the Artifact Procurement Interface
8.12. Denying Procurement for Everything Under a Group
8.13. Allowing Access to a Single Artifact in a Denied Group
8.14. Viewing the Effect of Composite Procurement Rules on the Tree
8.15. Effective Procurement Rules for a Particular Node
8.16. Stopping Procurement for a Procured Repository
8.17. Stop Procurement Confirmation Dialog
9.1. Without the Nexus Staging Suite
9.2. With Nexus Staging Suite
9.3. Supplying a Description for a Staging Release
9.4. Multi-level Staging and Build Promotion
9.5. Enterprise Menu after Staging Suite Installation
9.6. Adding a Repository Target for com.sonatype.sample
9.7. Multi-level Staging and Build Promotion
9.8. Editing a Staging Profile
9.9. Multi-level Staging and Build Promotion
9.10. Configuring a Build Promotion Profile
9.11. Assigning the Staging Deployer Role to the deployment user
9.12. Uploading a Staged Deployment in Nexus
9.13. Creating a Staging Ruleset
9.14. Associating a Staging Ruleset with a Staging Profile
9.15. Listing Repositories Associated with a Staging Profile
9.16. Confirmation and Description Dialog for Closing a Staging Repository
9.17. Closed Repository After Selecting Finish
9.18. Staging Repository Added to the End of a Repository Group
9.19. Viewing Nexus Managed Repositories
9.20. Browsing a Staging Repository
9.21. Browsing Repository via Staging Profiles
9.22. Promoting a Staging Repository
9.23. Selecting the Destination Repository for Staged Repository Promotion
9.24. Confirmation Dialog for Repository Promotion
9.25. Promoting a Staging Repository
9.26. Multi-level Staging and Build Promotion
9.27. Multi-level Staging and Build Promotion
9.28. Releasing, Promoting, and Dropping Build Promotion Profiles
9.29. Promoting Multiple Repositories to the Same Build Promotion Profile
10.1. The Maven Settings Panel
11.1. Creating an OSGi Bundle Proxy Repository
11.2. Creating a Hosted OSGi Bundle Repository
11.3. Creating a Virtual OSGi Bundle Repository from a Maven Repository
11.4. Creating a new OSGi Bundle Repository Group
12.1. Creating a P2 Proxy Repository
12.2. Creating a new P2 Repository Group
13.1. Adding a Hosted Repository
13.2. Creating a New Maven Site Repository
13.3. Newly Created Maven Site Repository
13.4. Adding the Site Deployment Role to the Deployment User
13.5. Sample Site Maven Project Web Site
14.1. Configuring the User Account Plugin
14.2. Sign Up Link Available for All Nexus Users
14.3. Nexus Sign Up Form
14.4. Nexus Sign Up Confirmation
14.5. Nexus Activation Email
14.6. Nexus Activation Email
14.7. User Interface with only the Base UI Privileges
14.8. Selecting Default Roles for New Users
15.1. Crowd Menu Link under the Security Section of the Nexus Menu
15.2. Crowd Configuration Panel
15.3. Crowd Access Settings
15.4. Crowd HTTP Settings
15.5. Crowd HTTP Proxy Settings
15.6. Crowd Miscellaneous Settings
15.7. Configuring the Crowd Authentication Realm
15.8. Creating a Nexus Crowd Application
15.9. Creating a Nexus Crowd Application Connection
15.10. Creating a Nexus Crowd Application Directories
15.11. Creating a Nexus Crowd Application Authorization
15.12. Adding an External Role Mapping
15.13. Mapping an External Crowd Group to a Nexus Role
15.14. Two Crowd Groups Mapped to Nexus Roles
15.15. Crowd Groups for User "brian"
15.16. Adding an External User Role Mapping
15.17. Locating a Crowd User in the User Role Mapping Dialog
15.18. Adding a Nexus Role to a Crowd User
16.1. Staging Upload Link
16.2. Uploading an Artifact Bundle
16.3. Staging Repository Created for Artifact Bundle Upload
16.4. Promoting a Staged Repository
16.5. Confirmation that Staged Repository has been Promoted
18.1. Layout of a Nexus Plugin Project
A.1. Creating an Artifactory System Export
A.2. Artifactory Import Panel from the Nexus Migration Plugin
A.3. Specifying the Artifactory System Backup Path
A.4. Configuring the Artifactory Import
A.5. Configuring Artifactory Group Imports
A.6. Merging a Proxy Repository During Artifactory Import
A.7. Configuring Users During Artifactory Import
A.8. Loading Artifactory Configuration Warning
A.9. Artifactory Import Scheduled Dialog
A.10. Viewing the Migration Logs
B.1. Archiva Managed Repositories
B.2. Editing an Archiva Managed Repository
B.3. Creating a Nexus Hosted Repository
B.4. Rebuilding the Index of a Nexus Hosted Repository
B.5. Browsing Archiva Remote Repositories
B.6. Archiva Proxy Connectors
B.7. Archiva Proxy Connector Settings
B.8. Creating a Nexus Proxy Repository
B.9. Adding a Proxy Repository to a Repository Group
B.10. Defining Nexus Repository Groups
Sonatype Promotion Subscribe via RSS