3

I would like to make a remote repository artifactory on a PHP satis repository.

Below is the configuration of the target satis repository:

{
  "name": "Satis",
  "homepage": "http://satis.server:48081",
  "repositories": [
       { "type": "composer", "url": "https://packagist.org" }
   ],
   "archive": {
      "directory": "dist",
      "format": "zip",
      "skip-dev": "true"
  },
  "require-dependencies": true,
  "require": {
    ...
  } 
}

Under artifactory, in the URL field I put: http://satis.server:48081

In composer setting, I chose the custom option, I tried to put in "http://satis.server:48081" in the fields "Download Url" and "Registry Url" without result.

Sorry for my poor english

thanks

user47
  • 31
  • 2

2 Answers2

1

First you need to create a remote PHP Composer repository in Artifactory pointing to your satis URL - http://satis.server:48081. This repository will proxy you satis repository.
After the repo is created, you need to configure composer to use this repository, for example:

{
    "repositories": [
        {"type": "composer", "url": "http://localhost:8081/artifactory/api/composer/satis-remote"},
        {"packagist": false}
    ]
}

You can use the Artifactory "Set Me Up" in order to get this configuration as well.

Dror Bereznitsky
  • 20,048
  • 3
  • 48
  • 57
0

Providing the terraform code to create the same. Here we create a remote repository to proxy the satis running as a standalone installation. Try to use the link with one of the service (like composer require .. ), then you will start seeing the artifacts getting cached/reflected under the remote repo URI.

resource "artifactory_remote_composer_repository" "php-satis" {

  key                   = "php-satis"
  url                   = "https://satis-url.internal"
  composer_registry_url = "https://satis-url.internal"
  repo_layout_ref       = "composer-default"
  vcs_git_provider      = "GITHUB"

}

I have tested the code with JFROG artifactory version 7.x and is working.

Kishor Unnikrishnan
  • 1,928
  • 4
  • 21
  • 33