From: Jessica Wagantall Date: Fri, 15 Jun 2018 02:48:29 +0000 (-0700) Subject: Add Nexus 2 repo docs. X-Git-Url: https://gerrit.linuxfoundation.org/infra/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F24%2F11324%2F8;p=releng%2Fdocs.git Add Nexus 2 repo docs. Add Nexus 2 documentation on repositories. This documentation contains a brief explanation on the repos used by most LF projects. Change-Id: I6c32876da8fc9d6576bbde6343a9880abbb7504c Issue-ID: RELENG-968 Signed-off-by: Jessica Wagantall --- diff --git a/docs/_static/jenkins-settings-files.png b/docs/_static/jenkins-settings-files.png new file mode 100644 index 0000000..f34fb34 Binary files /dev/null and b/docs/_static/jenkins-settings-files.png differ diff --git a/docs/nexus2.rst b/docs/nexus2.rst index dbcb260..7c6fa63 100644 --- a/docs/nexus2.rst +++ b/docs/nexus2.rst @@ -37,3 +37,72 @@ Alternately, users can access the repositories outside the GUI using the URL: Nexus 2 communicates with Jenkins server which is the interface used to make the artifacts publications on a scheduled or by demand basis (depending on the Jenkins JJB configuration for the particuar job). + +Nexus 2 Repositories +==================== + +Nexus 2 allows users to manage different types of repositories. To learn more about +how to manage them, please refer to `Sonatype's official documentation +`_. + +Most LF projects manage their Maven artifacts using the following repos: + +:Releases: (hosted) Official repository for released artifacts. Releases repositories have a + Disable re-deployment policy to avoid overwriting released versions. + +:Snapshots: (hosted) Used to publish Maven SNAPSHOT builds. In the project's pom.xml + these versions have a `-SNAPSHOT` suffix. + +Special repo namespaces: + +:Public Repositories: (group) A meta-url containing all release repos in a combined view. + +:Staging Repositories: (group) A meta-url containing all staging repos in a combined view. + Beware: oldest staging repo artifacts take precedence in cases where 2 staging repos + contain the same version artifact. + +:Proxy: Repositories that proxy artifacts from an upstream repository. + +Each repository is accessible via URL `https://nexus.example.org/content/repositories/`. + +For continuous integration builds, Jenkins has one settings file for each Gerrit repository. +Each settings file contains an entry for each accessible Nexus2 repository (ServerId). + +.. image:: _static/jenkins-settings-files.png + :alt: Jenkins settings files. + :align: center + +In the Gerrit repository's pom.xml, include the ServerIds in the following manner: + +.. code-block:: bash + + + + releases + Release Repository + ${project.nexus.url}/content/repositories/releases/ + + + staging + Staging Repository + ${project.nexus.url}/content/repositories/staging/ + + + snapshots + Snapshot Repository + ${project.nexus.url}/content/repositories/snapshots/ + + + +.. note:: + + More information on access configuration for each Gerrit repository in + :ref:`Create Nexus2 repos with lftools `. + +.. _create-repos-lftools: + +Create Nexus2 repos with lftools +================================ + +.. TODO: Creating Nexus2 repos using lftools (RELENG-954) +