Search...
Toggle theme

Artifactory Repository Manager

Configure JFrog Artifactory for NES Maven artifacts

This guide describes how to add the HeroDevs NES Maven Repository to a JFrog Artifactory instance.

  1. Create a Remote Repository for our private Maven repo
  2. Configure an existing (or create a new) Virtual Repository
  3. Verify your access

Create a Maven Remote Repository

  1. Under Administration, navigate to Repositories > and select Remote
  2. Select Create a Repository > Remote > Maven
  3. Configure the following on the Basic tab
    1. Note: See here for documentation on basic settings for Remote Repositories

Basic Settings

"Step 1 Basic"

Select Test to verify your token access.

Advanced Settings

Configure the following on the Advanced tab:

"Step 1 Advanced"

Configure a Virtual Repository

This step will provide configuration details to configure an Artifactory virtual repository used to access artifacts in Maven and Gradle projects.

Assumptions:

  • A Maven repository has been configured to access our NES Maven repository keyed as nes. (see Step 1)

If you already have a Virtual Repository configured with Maven Central (and potentially other sources) you can skip the following steps.

  1. Under Administration, navigate to Repositories > and select Virtual
  2. Select Create a Repository > Virtual > Maven
    • This sample keys the virtual repository with the name maven-default.

Whether creating or editing a new Virtual Repository, add nes-maven to the list of Selected Repositories.

Sample

"Virtual Maven Repository"

Verify Setup

Assuming your Virtual Repository was keyed as maven-default, and that you have a valid Artifactory token, configure your Maven settings or Gradle properties accordingly.

Maven (~/.m2/settings.xml)
Gradle (~/.gradle/gradle.properties)
<settings>
  <servers>
    <!-- other servers -->
    <server>
      <id>artifactory</id>
      <username>artifactory-user@email-address</username>
      <password>artifactory-token</password>
    </server>
  </servers>
  <profiles>
    <!-- other profiles -->
    <profile>
      <id>artifactory</id>
      <repositories>
        <repository>
          <id>artifactory</id>
          <name>maven-default</name>
          <url>https://company.jfrog.io/artifactory/maven-default</url>
        </repository>
      </repositories>
      <pluginRepositories>
        <pluginRepository>
          <id>artifactory</id>
          <name>maven-default</name>
          <url>https://company.jfrog.io/artifactory/maven-default</url>
        </pluginRepository>
      </pluginRepositories>
    </profile>
  </profiles>
  <activeProfiles>
    <!-- other active profiles -->
    <activeProfile>artifactory</activeProfile>
  </activeProfiles>
</settings>