Have a question? Want to report an issue?Contact JFrog support

Skip to end of metadata
Go to start of metadata

Overview

You can deploy artifacts into a local repository of Artifactory from theArtifactsmodule by clickingDeployto display theDeploydialog. Artifacts can be deployedindividuallyor in multiples.

Deploy link

Using Import to "deploy" a whole repository

If you want to "deploy" a whole repository, you should actually import it using theImport Repositoryfeature in theAdmintab underImport & Export | Repositories.


You can alsodeploy artifacts to any repositoryusingArtifactory's REST API, seethis example for a quick start.

Page Contents


Deploying a Single Artifact

To deploy a single artifact, simply fill in the fields in the Deploy dialog and click "Deploy".

Deploying a non-Maven artifact

Deploying According to Layout

TheDeploydialog displays the repository package type and layout configured. To deploy your package according to the configured layout, checkDeploy According to Layout.

Artifactory displays entry fields corresponding to the layout tokens for you to fill in.

Deploy by layout

If you are deploying a Maven artifact, you may need to configure additional attributes as described in the next section.

Suggested Target Path

Artifactory will suggest aTarget Pathbased on the details of your artifact (this works for both Maven and Ivy). For example, if a JAR artifact has an embedded POM under its internalMETA-INFdirectory, this information is used.

Deploying Maven Artifacts

If you are deploying an artifact that conforms to the Maven repository layout, you should setDeploy as Maven Artifactto expose fields that specify the corresponding Maven attributes -GroupID,ArtifactID,Version,ClassifierandType.

自动填充字段显示to the artifact name, however you can edit them and your changes will also be reflected in theTarget Path.

If your target repository does not include a POM, setGenerate Default POM/Deploy Jar's Internal POM, to use the POM within the artifact you are deploying, or generate a default POM respectively.

Take care when editing the POM manually

If you are editing the POM manually, be very careful to keep it in a valid state.

Deploying a Maven artifactDeploying a Maven artifact


Deploying with Properties

Properties can be attached to the uploaded file by specifying them on theTarget Path.

First, unset theDeploy as Maven Artifactcheck box, if necessary.

Then, in theTargetPathfield,add the properties delimited from the path and from each other by semicolons.

For example, to upload an artifact with the propertyqaset to "passed", andbuild.numberset to "102", use the followingTarget Path:

dir1/file.zip;qa=passed;build.number=102

Deploying with Multiple Properties

To deploy multiple values to the same key add the same key again with the new value, e.g.key1=value1;key1=value2will deploy the file with propertykey1with value ofvalue1,value2.

For example, to upload a file with property passed and values qa, stress use the followingTarget Path:

dir1/file.zip;passed=qa;passed=stress

Deploying Multiple Files

To deploy multiple files together, simple set the deployTypetoMulti,fill in the rest of the fields in the dialog and click "Deploy".


Deploying an Artifact Bundle

An artifact bundle is deployed as a set of artifacts packaged in an archive with one of the following supported extensions: zip, tar, tar.gz, tgz.

When you specify that an artifact should be deployed as a bundle, Artifactory will extract the archive contents when you deploy it.

File structure within the archive

Artifacts should be packaged within the archive in the same file structure with which they should be deployed to the target repository.

To deploy an artifact bundle, in theDeploydialog, first upload the archive file you want to deploy.

Check theDeploy as Bundle Artifactcheckbox and clickDeploy.

Deploying an artifact bundle


Deploying to a Virtual Repository

From version 4.2, Artifactory supports deploying artifacts to a virtual repository.

To enable this, you first need to designate one of the local repositories that is aggregated by the virtual repository as a deployment target. This can be done through the UI by setting theDefault Deployment Repositoryin theBasic Settingsof theEdit Repositoryscreen.

Setting the default deployment repository for a virtual repository

You can also set the Default Deployment Repository using thedefaultDeploymentRepoparameter of theVirtual Repository Configuration JSONused in theCreate or Replace Repository ConfigurationandUpdate Repository ConfigurationREST API endpoints. Once the deployment target is configured, you may deploy artifacts to it using any packaging format client configured to work with Artifactory. For example,docker push, npm publish, NuGet push, gem pushetc.

You can also use Artifactory's REST API todeploy an artifactand use the virtual repository key in the path to deploy.

From version 4.4, if you do specify aDefault Deployment Repositoryfor a virtual repository, the correspondingSet Me Updialog for the repository will also include instructions and code snippets for deploying to that repository.


Failed Uploads

The most common reasons for a rejected deployment are:

  • Lack of permissions
  • A conflict with the target repository's includes/excludes patterns
  • A conflict with the target repository's snapshots/releases handling policy.

  • No labels