Step 6: Artifact Management
Time: 8 minutes
Purpose: Configure access to package repositories and dependency management
Company-Specific Setup
If you're using company-managed artifact repositories, complete the Ybor Employee Onboarding first for JFrog Artifactory SSO setup and token generation.
Overview
Most development projects require access to:
- Public package repositories (npm, Maven Central, PyPI, etc.)
- Private/company package repositories
- Internal libraries and dependencies
This step covers configuring access to these repositories.
Public Repository Access
Node.js (npm/yarn)
# Verify npm is working
npm config get registry
# Should show: https://registry.npmjs.org/
# Optional: Configure npm for faster installs
npm config set registry https://registry.npmjs.org/
npm config set progress false
Java (Maven/Gradle)
# Maven uses ~/.m2/settings.xml for configuration
# Gradle uses ~/.gradle/gradle.properties
# Verify Maven installation
mvn --version
# Verify Gradle installation
gradle --version
Python (pip)
# Verify pip is working
pip config list
# Optional: Configure pip for faster installs
pip config set global.timeout 60
pip config set global.retries 5
Private Repository Access (Optional)
If your organization uses private repositories, you'll need authentication credentials:
Generic Authentication Setup
# Example environment variables for private repositories
export PACKAGE_REGISTRY_USERNAME="your_username"
export PACKAGE_REGISTRY_TOKEN="your_token"
export PACKAGE_REGISTRY_URL="https://your-registry.example.com"
Tool-Specific Configuration
npm with private registry
# Configure npm for private registry
npm config set registry https://your-registry.example.com/npm/
npm config set //your-registry.example.com/npm/:_authToken="your_token"
Maven with private repository
Add to ~/.m2/settings.xml
:
<settings>
<servers>
<server>
<id>your-repo</id>
<username>your_username</username>
<password>your_token</password>
</server>
</servers>
</settings>
Gradle with private repository
Add to ~/.gradle/gradle.properties
:
yourRepoUsername=your_username
yourRepoPassword=your_token
Verification
# Test public repository access
npm view react version # Should show latest React version
pip show setuptools # Should show package info
mvn help:evaluate -Dexpression=maven.version -q -DforceStdout # Maven version
# Test private repository access (if configured)
# This depends on your specific setup and available packages
Troubleshooting
Public Repository Issues
- Network connectivity: Check internet connection
- Firewall/proxy: Configure corporate proxy if needed
- DNS issues: Try different DNS servers
Private Repository Issues
- Authentication: Verify username/token are correct
- Network access: Ensure you can reach the repository URL
- Permissions: Confirm you have access to the specific repositories
- Token expiry: Check if authentication tokens need renewal