Code Monkey home page Code Monkey logo

portus's Introduction

Portus

Portus is an authorization server and a user interface for the next generation of the Docker registry. Portus targets version 2 of the Docker Registry API. The minimum required version of Registry is 2.1, which is the first version supporting soft deletes of blobs.

master v2.0 Code Climate
Build Status Build Status Code Climate Test Coverage

Features

Fine-grained control of permissions

Portus supports the concept of users and teams. Users have their own personal Docker namespace where they have both read (aka docker pull) and write (aka docker push) access. A team is a group of users that have read and write access to a certain namespace. You can read more about this in our documentation page about it.

Portus implements the token based authentication system described by the new version of the Docker registry. This can be used to have full control over the images served by an instance of the Docker registry.

Web interface for Docker registry

Portus provides quick access to all the images available on your private instance of Docker registry. User's privileges are taken into account to make sure private images (the ones requiring special rights also for docker pull) are not shown to unauthorized personnel.

Self-hosted

Portus allows you to host everything on your servers, on your own infrastructure. You don't have to trust a third-party service, just own everything yourself. Take a look at our documentation to read the different setups in which you can deploy Portus.

And more!

Some highlights:

Take a tour by our documentation site to read more about this.

Supported versions

Docker technologies have a fast iteration pace. This is a good thing, but it comes with some challenges. As requested by some of our users, the following table shows which versions of Docker and Docker Distribution are supported by each Portus version:

Portus Docker Engine Docker Distribution
master 1.6+ 2.0+
2.0.0 & 2.0.1 1.6 to 1.9 2.0 to 2.2
2.0.2 1.6 to 1.9 2.0+
2.0.3+ 1.6+ 2.0+

Let's detail some of the version being specified:

  • Docker Engine 1.6 is the first version supported by Docker Distribution 2. Therefore, this requirement is also the same for Portus.
  • As of Docker 1.10, the Manifest Version 2, Schema 2 is the one being used. This is only supported by Portus in the master branch and in 2.0.3.
  • Docker Distribution 2.3 supports both Manifest versions, but some changes had to be made in order to offer backwards compatibility. This is not supported neither for Portus 2.0.0 nor 2.0.1.

Overview

In this video you can get an overview of some of the features and capabilities of Portus.

preview

Contributing

First of all, make sure that you have a working development environment. You can easily do this with either Docker or Vagrant, as it's explained on the wiki. The wiki also has notable pages like How we test Portus.

Also, make sure to understand our contribution guidelines, as explained in this document.

Happy hacking!

Licensing

Portus is licensed under the Apache License, Version 2.0. See LICENSE for the full license text.

portus's People

Contributors

arcticsnowman avatar cyntss avatar cyphar avatar databus23 avatar depay avatar eotchi avatar farmerworking avatar flavio avatar geoaxis avatar jordimassaguerpla avatar kalabiyau avatar leshik avatar lonewulf avatar lsamayoa avatar msfernandes avatar mssola avatar rds13 avatar salzig avatar sshipway avatar vpereira avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

portus's Issues

ssl error on catalogjob / no sync between registry and portus

I've set up a stack on rancher using the community-catalog - I've provided a directory on a shared volume and a fqdn (for a self-signed certificate which created during setup for me)

After the app-stack launched everything works fine, except the sync between registry and portus.
In your security paragraph of the README you wrote for the self-signed cert: '[...] this can be replaced if necessary.'

So Issumed it is possible to use this whole setup with a self-signed cert, escpecially this setup will run in a private, non-public environment, isn't it?

The logfile shows:

12/23/2016 2:59:19 PMI, [2016-12-23T13:59:19.037270 SUSE#85] INFO -- : Perform CatalogJob
12/23/2016 2:59:19 PMException: SSL_connect returned=1 errno=0 state=unknown state: certificate verify failed
12/23/2016 2:59:19 PMI, [2016-12-23T13:59:19.082428 SUSE#85] INFO -- : Finished CatalogJob in 0.04 seconds

Is there any Parameter which I overlook or a bug?

Thanks in advance!

using with convoy-NFS

I am trying to get working using convoy-nfs as the storage backend for the shared storage. Any suggestions?

Portus - NGINX error

I have been using Portus for about 6 months now and it has been flawless. I am attempting to redeploy on new infrastructure and Rancher 1.1.2, Docker 1.12. I am using my own "real" certificates.

The SSLProxy container fails to launch with this error.
nginx: [emerg] host not found in upstream "portus" in /etc/nginx/conf.d/portus.conf:9

This is my docker compose file:

sslproxy:
  labels:
    io.rancher.scheduler.affinity:container_label_soft: registry.portus.db=1
    io.rancher.scheduler.affinity:host_label: name=rancherpool-pvt
  tty: true
  image: nginx:1.9.9
  links:
  - portus:portus
  volumes:
  - /efs/data/registry/certs:/etc/nginx/certs:ro
  - /efs/data/registry/proxy:/etc/nginx/conf.d:ro  
  stdin_open: true
lb:
  ports:
  - 5000:5000/tcp
  - 443:443/tcp
  labels:
    io.rancher.scheduler.global: 'false'
    io.rancher.loadbalancer.target.sslproxy: 443=443
    io.rancher.scheduler.affinity:host_label: name=rancherpool-pvt
    io.rancher.loadbalancer.target.registry: 5000=5000
  tty: true
  image: rancher/load-balancer-service
  links:
  - registry:registry
  - sslproxy:sslproxy
  stdin_open: true
registry:
  environment:
    REGISTRY_AUTH: token
    REGISTRY_AUTH_TOKEN_ISSUER: reg.domain.com
    REGISTRY_AUTH_TOKEN_REALM: https://reg.domain.com:443/v2/token
    REGISTRY_AUTH_TOKEN_ROOTCERTBUNDLE: /certs/registry.crt
    REGISTRY_AUTH_TOKEN_SERVICE: reg.domain.com:5000
    REGISTRY_HTTP_SECRET: httpsecret
    REGISTRY_HTTP_TLS_CERTIFICATE: /certs/registry.crt
    REGISTRY_HTTP_TLS_KEY: /certs/registry.key
    REGISTRY_LOG_LEVEL: warn
    REGISTRY_NOTIFICATIONS_ENDPOINTS: |-
      - name: portus
        url: http://portus:3000/v2/webhooks/events
        timeout: 500
        threshold: 5
        backoff: 1
    REGISTRY_STORAGE_DELETE_ENABLED: 'true'
  log_driver: ''
  labels:
    io.rancher.scheduler.affinity:host_label: name=rancherpool-pvt
  log_opt: {}
  image: registry:2.3.1
  links:
  - portus:portus
  volumes:
  - /efs/data/registry/certs:/certs:rw
  - /efs/data/registry/data:/var/lib/registry:rw
portus:
  environment:
    PORTUS_CHECK_SSL_USAGE_ENABLED: 'true'
    PORTUS_GRAVATAR_ENABLED: 'true'
    PORTUS_KEY_PATH: /certs/registry.key
    PORTUS_MACHINE_FQDN: reg.domain.com
    PORTUS_PASSWORD: password$$
    PORTUS_PORT: '443'
    PORTUS_PRODUCTION_DATABASE: portus
    PORTUS_PRODUCTION_HOST: aws.database.rds.amazonaws.com
    PORTUS_PRODUCTION_PASSWORD: password$$
    PORTUS_PRODUCTION_USERNAME: username
    PORTUS_SECRET_KEY_BASE: password$$
    PORTUS_SMTP_ENABLED: 'false'
    REGISTRY_HOSTNAME: reg.domain.com
    REGISTRY_NAME: Registry
    REGISTRY_PORT: '5000'
    REGISTRY_SSL_ENABLED: 'true'
  log_driver: ''
  labels:
    registry.portus.app: '1'
    io.rancher.container.pull_image: always
    io.rancher.scheduler.affinity:host_label: name=rancherpool-pvt
  log_opt: {}
  image: sshipway/portus:2.0.5
  volumes:
  - /efs/data/registry/certs:/certs:rw
  - /efs/data/registry/proxy:/etc/nginx/conf.d:rw

How to build the container myself

I would like to package the newest portus for e.g. deleting images and more.
Is there any way i could do this myself is your Dockerfile available?

How to using https in portus

Hi,

I'm installed portus from rancher catalog.

And registry pull/push is working fine.

But portus can't show registry images.

I check the portus log :

I, [2016-06-07T02:51:02.070362 #69]  INFO -- : Perform CatalogJob
Exception: SSL_connect returned=1 errno=0 state=unknown state: certificate verify failed
I, [2016-06-07T02:51:02.124608 #69]  INFO -- : Finished CatalogJob in 0.05 seconds
I, [2016-06-07T02:56:02.072536 #69]  INFO -- : Perform CatalogJob
Exception: SSL_connect returned=1 errno=0 state=unknown state: certificate verify failed
I, [2016-06-07T02:56:02.115447 #69]  INFO -- : Finished CatalogJob in 0.04 seconds
[80] 10.42.66.227 - - [07/Jun/2016:02:58:38 +0000] "POST /v2/webhooks/events HTTP/1.1" 202 - 0.1084
Completed 200 OK in 133ms (Views: 0.2ms | ActiveRecord: 14.3ms)
[80] 10.42.83.221 - - [07/Jun/2016:02:58:38 +0000] "GET /v2/token?account=admin&scope=repository%3Acloud%2Fsensitive-service-provider%3Apush%2Cpull&service=registry.coramo.com%3A5000 HTTP/1.1" 200 - 0.1380
Started POST "/v2/webhooks/events" for 10.42.66.227 at 2016-06-07 02:58:38 +0000
Processing by Api::V2::EventsController#create as JSON
Completed 202 Accepted in 1ms (ActiveRecord: 0.0ms)
[80] 10.42.66.227 - - [07/Jun/2016:02:58:38 +0000] "POST /v2/webhooks/events HTTP/1.1" 202 - 0.0042
Started GET "/v2/token?account=admin&scope=repository%3Acloud%2Fsensitive-service-provider%3Apush%2Cpull&service=registry.coramo.com%3A5000" for 10.42.83.221 at 2016-06-07 02:58:38 +0000
Processing by Api::V2::TokensController#show as JSON
  Parameters: {"account"=>"admin", "scope"=>"repository:cloud/sensitive-service-provider:push,pull", "service"=>"registry.coramo.com:5000"}
Completed 200 OK in 114ms (Views: 0.3ms | ActiveRecord: 5.4ms)
[80] 10.42.83.221 - - [07/Jun/2016:02:58:38 +0000] "GET /v2/token?account=admin&scope=repository%3Acloud%2Fsensitive-service-provider%3Apush%2Cpull&service=registry.coramo.com%3A5000 HTTP/1.1" 200 - 0.1176
Started POST "/v2/webhooks/events" for 10.42.66.227 at 2016-06-07 02:58:38 +0000
Processing by Api::V2::EventsController#create as JSON
Completed 202 Accepted in 1ms (ActiveRecord: 0.0ms)
[74] 10.42.83.221 - - [07/Jun/2016:02:58:38 +0000] "GET /v2/token?account=admin&scope=repository%3Acloud%2Fsensitive-service-provider%3Apush%2Cpull&service=registry.coramo.com%3A5000 HTTP/1.1" 200 - 0.1130
Started POST "/v2/webhooks/events" for 10.42.66.227 at 2016-06-07 02:58:38 +0000
Processing by Api::V2::EventsController#create as JSON
Handling Push event:
{
  "id": "9e3e0baf-64b8-48c2-84e5-885b95a688d4",
  "timestamp": "2016-06-07T02:58:38.728755171Z",
  "action": "push",
  "target": {
    "mediaType": "application/vnd.docker.distribution.manifest.v2+json",
    "size": 3638,
    "digest": "sha256:1be17b1d2ad2814882c440f27ba5fef12e2cd74e236adc59c67f06b088a16dd9",
    "length": 3638,
    "repository": "cloud/sensitive-service-provider",
    "url": "https://registry.coramo.com:5000/v2/cloud/sensitive-service-provider/manifests/sha256:1be17b1d2ad2814882c440f27ba5fef12e2cd74e236adc59c67f06b088a16dd9"
  },
  "request": {
    "id": "aefae438-e5ed-4ab9-b450-1787b1581164",
    "addr": "10.42.213.193:43704",
    "host": "registry.coramo.com:5000",
    "method": "PUT",
    "useragent": "docker/1.10.3 go/go1.5.3 git-commit/20f81dd kernel/3.10.0-327.13.1.el7.x86_64 os/linux arch/amd64"
  },
  "actor": {
    "name": "admin"
  },
  "source": {
    "addr": "151904afe8cf:5000",
    "instanceID": "f542855b-fda6-4604-a0a8-222f8f77a637"
  }
}
Could not fetch the tag for target {"mediaType"=>"application/vnd.docker.distribution.manifest.v2+json", "size"=>3638, "digest"=>"sha256:1be17b1d2ad2814882c440f27ba5fef12e2cd74e236adc59c67f06b088a16dd9", "length"=>3638, "repository"=>"cloud/sensitive-service-provider", "url"=>"https://registry.coramo.com:5000/v2/cloud/sensitive-service-provider/manifests/sha256:1be17b1d2ad2814882c440f27ba5fef12e2cd74e236adc59c67f06b088a16dd9"}
Reason: SSL_connect returned=1 errno=0 state=unknown state: certificate verify failed
Completed 202 Accepted in 22ms (ActiveRecord: 1.1ms)
[74] 10.42.66.227 - - [07/Jun/2016:02:58:38 +0000] "POST /v2/webhooks/events HTTP/1.1" 202 - 0.0246

please help me.

Not responding on Docker 17.06.2-ce

I have just created a stack on top of the latest 17.06 docker and it had already some naming problems with the volumes due to forward slashes. I created a PR for this on the catalogue.
rancher/community-catalog#615

But also I get a

ERR_EMPTY_RESPONSE

When calling my registry UX (portus) on port 5443.
I am unfamiliar with portus and I was wondering if you could suggest what I can look for to fix it?

The docker compose i used while PR is reviewed

version: '2'
services:
  registry:
    image: registry:2.3.1
    environment:
      REGISTRY_AUTH: token
      REGISTRY_AUTH_TOKEN_ISSUER: registry.Biz.link
      REGISTRY_AUTH_TOKEN_REALM: https://registry.Biz.link:5443/v2/token
      REGISTRY_AUTH_TOKEN_ROOTCERTBUNDLE: /certs/registry.crt
      REGISTRY_AUTH_TOKEN_SERVICE: registry.Biz.link:5000
      REGISTRY_HTTP_SECRET: httpsecret
      REGISTRY_HTTP_TLS_CERTIFICATE: /certs/registry.crt
      REGISTRY_HTTP_TLS_KEY: /certs/registry.key
      REGISTRY_LOG_LEVEL: warn
      REGISTRY_NOTIFICATIONS_ENDPOINTS: |
        - name: portus
          url: http://portus:3000/v2/webhooks/events
          timeout: 500
          threshold: 5
          backoff: 1
      REGISTRY_STORAGE_DELETE_ENABLED: 'true'
    stdin_open: true
    volumes:
    - BizRegistry-Certs:/certs
    - BizRegistry-Data:/var/lib/registry
    tty: true
    links:
    - portus:portus
  lb:
    image: rancher/lb-service-haproxy:v0.7.9
    stdin_open: true
    tty: true
    ports:
    - 5000:5000/tcp
    - 5443:5443/tcp
    labels:
      io.rancher.container.agent.role: environmentAdmin
      io.rancher.container.create_agent: 'true'
      io.rancher.scheduler.affinity:not_host_label: registry.enabled=false
      io.rancher.scheduler.global: 'true'
  sslproxy:
    image: nginx:1.9.9
    stdin_open: true
    volumes:
    - BizRegistry-Certs:/etc/nginx/certs:ro
    - BizRegistry-Proxy:/etc/nginx/conf.d:ro
    tty: true
    links:
    - portus:portus
    labels:
      io.rancher.scheduler.affinity:container_label_soft: registry.portus.db=1
  db:
    image: mysql:5.7.10
    environment:
      MYSQL_DATABASE: portus
      MYSQL_PASSWORD: '}4?Gxxxxx'
      MYSQL_ROOT_PASSWORD: 0jDIxxxxxx
      MYSQL_USER: portus
    stdin_open: true
    volumes:
    - BizRegistry-Db:/var/lib/mysql
    tty: true
    labels:
      registry.portus.db: '1'
  portus:
    image: sshipway/portus:2.0.5
    environment:
      PORTUS_CHECK_SSL_USAGE_ENABLED: 'true'
      PORTUS_GRAVATAR_ENABLED: 'true'
      PORTUS_KEY_PATH: /certs/registry.key
      PORTUS_LDAP_AUTHENTICATION_BIND_DN: ou=portus,dc=company,dc=com
      PORTUS_LDAP_AUTHENTICATION_ENABLED: 'false'
      PORTUS_LDAP_AUTHENTICATION_PASSWORD: password
      PORTUS_LDAP_BASE: ou=People,dc=company,dc=com
      PORTUS_LDAP_ENABLED: 'false'
      PORTUS_LDAP_GUESS_EMAIL_ATTR: mail
      PORTUS_LDAP_GUESS_EMAIL_ENABLED: 'true'
      PORTUS_LDAP_HOSTNAME: ldap.company.com
      PORTUS_LDAP_METHOD: starttls
      PORTUS_LDAP_PORT: '389'
      PORTUS_LDAP_UID: cn
      PORTUS_MACHINE_FQDN: registry.Biz.link
      PORTUS_PASSWORD: '}4?Gl=bD;S91cERr'
      PORTUS_PORT: '5443'
      PORTUS_PRODUCTION_DATABASE: portus
      PORTUS_PRODUCTION_HOST: db
      PORTUS_PRODUCTION_PASSWORD: '}4?Gxxxxxxx'
      PORTUS_PRODUCTION_USERNAME: portus
      PORTUS_SECRET_KEY_BASE: 0jDISxxxxx
      PORTUS_SMTP_ENABLED: 'false'
      REGISTRY_HOSTNAME: registry.Biz.link
      REGISTRY_NAME: Registry
      REGISTRY_PORT: '5000'
      REGISTRY_SSL_ENABLED: 'true'
    stdin_open: true
    volumes:
    - BizRegistry-Certs:/certs
    - BizRegistry-Proxy:/etc/nginx/conf.d
    tty: true
    links:
    - db:db
    labels:
      registry.portus.app: '1'
      io.rancher.scheduler.affinity:container_label_soft: registry.portus.db=1
      io.rancher.container.pull_image: always

Update to Version 2.1

Hi,
this is more a request than an issue: will you be updating this project to the current 2.1 version?
This would be great, since deleting of images was introduced with this version.

Thanks for your work! :-)

net::ERR_CONTENT_LENGTH_MISMATCH

Deploying from the registry-convoy rancher community catalog entry (without LDAP), the sign up page loads without CSS and get this error (when connecting to the load balancer).

GET https://example.org/assets/application-9bf189edb6b30009b53dd9b0f49fc59d.css net::ERR_CONTENT_LENGTH_MISMATCH
sign_up:1 GET https://example.org/assets/application-febd0e81a3221047d447ed25f2d0b036.js net::ERR_CONTENT_LENGTH_MISMATCH

Not sure if it has anything to do with it but when doing rake portus:info it shows that the version is 2.1.0-dev (when I was expecting 2.0.5).

Issue getting going using Rancher Catalog

Hello,

Attempting to set this up using the Rancher Catalog template. Using convoy-efs for storage, and that seems fine. Once everything gets going I get mysql errors from Portus. Its using sshipway/portus:2.0.5

10/28/2016 2:36:31 PMMysql2::Error (Host '10.42.31.240' is not allowed to connect to this MySQL server):

It has this problem trying to run migrations and accessing the sites as well, thus throwing a 500.

no implicit conversion of Fixnum into String error when launched via rancher catalog

When the service stack is launched from rancher catalog, the following error in portus service is seen repeatedly after the stack has turned green:

WARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
/usr/local/bundle/gems/activesupport-4.2.2/lib/active_support/key_generator.rb:21:in `pbkdf2_hmac_sha1': no implicit conversion of Fixnum into String (TypeError)
[Mailer config] Host: xxxx.xx.xx (registry FQDN specified in config)
[Mailer config] Protocol: https://
fatal: Not a git repository (or any of the parent directories): .git

Full startup log has been attached.
portus_error.txt

Using external SQL server

I would like to use a mysql server I already have.

Can I modify these settings like this? (Not sure about the port setting) and remove the link to the db container?

PORTUS_PRODUCTION_DATABASE: portus
PORTUS_PRODUCTION_HOST: databasehostname:3306
PORTUS_PRODUCTION_PASSWORD: SOMEPASSWORD
PORTUS_PRODUCTION_USERNAME: portus

rancher template is broken

docker-compose

db:
  environment:
    MYSQL_DATABASE: portus
    MYSQL_PASSWORD: password
    MYSQL_ROOT_PASSWORD: password
    MYSQL_USER: portus
  labels:
    registry.portus.db: '1'
  tty: true
  image: mysql:5.7.10
  volumes:
  - /srv/docker/services/docker-registry/db:/var/lib/mysql
  stdin_open: true
sslproxy:
  labels:
    io.rancher.scheduler.affinity:container_label_soft: registry.portus.db=1
  tty: true
  image: nginx:1.9.9
  links:
  - portus:portus
  volumes:
  - /srv/docker/services/docker-registry/certs:/etc/nginx/certs:ro
  - /srv/docker/services/docker-registry/proxy:/etc/nginx/conf.d:ro
  stdin_open: true
lb:
  ports:
  - 5000:5000/tcp
  - 443:443/tcp
  labels:
    io.rancher.scheduler.global: 'true'
    io.rancher.scheduler.affinity:not_host_label: registry.enabled=false
    io.rancher.loadbalancer.target.sslproxy: 443=443
    io.rancher.loadbalancer.target.registry: 5000=5000
  tty: true
  image: rancher/load-balancer-service
  links:
  - registry:registry
  - sslproxy:sslproxy
  stdin_open: true
registry:
  environment:
    REGISTRY_AUTH: token
    REGISTRY_AUTH_TOKEN_ISSUER: registry.thelma.lan
    REGISTRY_AUTH_TOKEN_REALM: https://registry.thelma.lan:443/v2/token
    REGISTRY_AUTH_TOKEN_ROOTCERTBUNDLE: /certs/registry.crt
    REGISTRY_AUTH_TOKEN_SERVICE: registry.thelma.lan:5000
    REGISTRY_HTTP_SECRET: httpsecret
    REGISTRY_HTTP_TLS_CERTIFICATE: /certs/registry.crt
    REGISTRY_HTTP_TLS_KEY: /certs/registry.key
    REGISTRY_LOG_LEVEL: warn
    REGISTRY_NOTIFICATIONS_ENDPOINTS: |
      - name: portus
        url: http://portus:3000/v2/webhooks/events
        timeout: 500
        threshold: 5
        backoff: 1
    REGISTRY_STORAGE_DELETE_ENABLED: 'true'
  tty: true
  image: registry:2.3.1
  links:
  - portus:portus
  volumes:
  - /srv/docker/services/docker-registry/certs:/certs
  - /srv/docker/services/docker-registry/data:/var/lib/registry
  stdin_open: true
portus:
  environment:
    PORTUS_CHECK_SSL_USAGE_ENABLED: 'true'
    PORTUS_GRAVATAR_ENABLED: 'true'
    PORTUS_KEY_PATH: /certs/registry.key
    PORTUS_LDAP_AUTHENTICATION_BIND_DN: ou=portus,dc=company,dc=com
    PORTUS_LDAP_AUTHENTICATION_ENABLED: 'false'
    PORTUS_LDAP_AUTHENTICATION_PASSWORD: password
    PORTUS_LDAP_BASE: ou=People,dc=company,dc=com
    PORTUS_LDAP_ENABLED: 'false'
    PORTUS_LDAP_GUESS_EMAIL_ATTR: mail
    PORTUS_LDAP_GUESS_EMAIL_ENABLED: 'true'
    PORTUS_LDAP_HOSTNAME: ldap.company.com
    PORTUS_LDAP_METHOD: starttls
    PORTUS_LDAP_PORT: '389'
    PORTUS_LDAP_UID: cn
    PORTUS_MACHINE_FQDN: registry.thelma.lan
    PORTUS_PASSWORD: password
    PORTUS_PORT: '443'
    PORTUS_PRODUCTION_DATABASE: portus
    PORTUS_PRODUCTION_HOST: db
    PORTUS_PRODUCTION_PASSWORD: password
    PORTUS_PRODUCTION_USERNAME: portus
    PORTUS_SECRET_KEY_BASE: password
    PORTUS_SMTP_ENABLED: 'false'
    REGISTRY_HOSTNAME: registry.thelma.lan
    REGISTRY_NAME: Registry
    REGISTRY_PORT: '5000'
    REGISTRY_SSL_ENABLED: 'true'
  labels:
    registry.portus.app: '1'
    io.rancher.container.pull_image: always
    io.rancher.scheduler.affinity:container_label_soft: registry.portus.db=1
  tty: true
  image: sshipway/portus:2.0.5
  links:
  - db:db
  volumes:
  - /srv/docker/services/docker-registry/certs:/certs
  - /srv/docker/services/docker-registry/proxy:/etc/nginx/conf.d
  stdin_open: true

rancher-compose

db:
  scale: 1
sslproxy:
  scale: 1
lb:
  load_balancer_config:
    haproxy_config: {}
  health_check:
    port: 42
    interval: 2000
    unhealthy_threshold: 3
    strategy: recreate
    response_timeout: 2000
    healthy_threshold: 2
registry:
  scale: 1
portus:
  scale: 1

Trying to initially access the web app
2016-12-29_08-00-38

portus logs

12/29/2016 7:52:16 AMrake aborted!
12/29/2016 7:52:16 AMMysql2::Error: Can't connect to MySQL server on 'db' (111)
12/29/2016 7:52:16 AM/portus/lib/tasks/portus.rake:4:in `block (2 levels) in <top (required)>'
12/29/2016 7:52:16 AMTasks: TOP => portus:create_api_account
12/29/2016 7:52:16 AM(See full trace by running task with --trace)
12/29/2016 7:52:16 AMCreating rancher password
12/29/2016 7:52:17 AMWARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
12/29/2016 7:52:18 AM[Mailer config] Host:     registry.thelma.lan
12/29/2016 7:52:18 AM[Mailer config] Protocol: https://
12/29/2016 7:52:18 AMfatal: Not a git repository (or any of the parent directories): .git
12/29/2016 7:52:18 AMError running migration! Please review database configuration
12/29/2016 7:52:18 AMYou have to provide a value for `password'
12/29/2016 7:52:18 AMChecking registry definition for registry.thelma.lan:5000
12/29/2016 7:52:19 AMWARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
12/29/2016 7:52:20 AM[Mailer config] Host:     registry.thelma.lan
12/29/2016 7:52:20 AM[Mailer config] Protocol: https://
12/29/2016 7:52:20 AMfatal: Not a git repository (or any of the parent directories): .git
12/29/2016 7:52:20 AMError running migration! Please review database configuration
12/29/2016 7:52:20 AMrake aborted!
12/29/2016 7:52:20 AMMysql2::Error: Can't connect to MySQL server on 'db' (111)
12/29/2016 7:52:20 AM/portus/lib/tasks/sshipway.rake:11:in `block (2 levels) in <top (required)>'
12/29/2016 7:52:20 AMTasks: TOP => sshipway:registry
12/29/2016 7:52:20 AM(See full trace by running task with --trace)
12/29/2016 7:52:20 AMStarting chrono
12/29/2016 7:52:20 AMStarting Portus
12/29/2016 7:52:20 AM[72] Puma starting in cluster mode...
12/29/2016 7:52:20 AM[72] * Version 2.14.0 (ruby 2.2.2-p95), codename: Fuchsia Friday
12/29/2016 7:52:20 AM[72] * Min threads: 0, max threads: 16
12/29/2016 7:52:20 AM[72] * Environment: development
12/29/2016 7:52:20 AM[72] * Process workers: 3
12/29/2016 7:52:20 AM[72] * Phased restart available
12/29/2016 7:52:20 AM[72] * Listening on tcp://0.0.0.0:3000
12/29/2016 7:52:20 AM[72] Use Ctrl-C to stop
12/29/2016 7:52:21 AMWARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
12/29/2016 7:52:21 AMWARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
12/29/2016 7:52:21 AMWARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
12/29/2016 7:52:21 AMWARNING: Nokogiri was built against LibXML version 2.9.1, but has dynamically loaded 2.8.0
12/29/2016 7:52:22 AM[Mailer config] Host:     registry.thelma.lan
12/29/2016 7:52:22 AM[Mailer config] Protocol: https://
12/29/2016 7:52:22 AMfatal: Not a git repository (or any of the parent directories): .git
12/29/2016 7:52:22 AM[Mailer config] Host:     registry.thelma.lan
12/29/2016 7:52:22 AM[Mailer config] Protocol: https://
12/29/2016 7:52:22 AM[Mailer config] Host:     registry.thelma.lan
12/29/2016 7:52:22 AM[Mailer config] Protocol: https://
12/29/2016 7:52:22 AM[Mailer config] Host:     registry.thelma.lan
12/29/2016 7:52:22 AM[Mailer config] Protocol: https://
12/29/2016 7:52:22 AMfatal: Not a git repository (or any of the parent directories): .git
12/29/2016 7:52:22 AMfatal: Not a git repository (or any of the parent directories): .git
12/29/2016 7:52:22 AMfatal: Not a git repository (or any of the parent directories): .git
12/29/2016 7:52:22 AMError running migration! Please review database configuration
12/29/2016 7:52:23 AM[72] - Worker 0 (pid: 76) booted, phase: 0
12/29/2016 7:52:23 AMError running migration! Please review database configuration
12/29/2016 7:52:23 AMError running migration! Please review database configuration
12/29/2016 7:52:23 AM[72] - Worker 2 (pid: 84) booted, phase: 0
12/29/2016 7:52:23 AMError running migration! Please review database configuration
12/29/2016 7:52:23 AMCan't connect to MySQL server on 'db' (111)
12/29/2016 7:52:23 AM/usr/local/bundle/gems/mysql2-0.3.18/lib/mysql2/client.rb:70:in `connect'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/mysql2-0.3.18/lib/mysql2/client.rb:70:in `initialize'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in `new'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/mysql2_adapter.rb:18:in `mysql2_connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:438:in `new_connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:448:in `checkout_new_connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:422:in `acquire_connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:349:in `block in checkout'
12/29/2016 7:52:23 AM/usr/local/lib/ruby/2.2.0/monitor.rb:211:in `mon_synchronize'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:348:in `checkout'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:263:in `block in connection'
12/29/2016 7:52:23 AM/usr/local/lib/ruby/2.2.0/monitor.rb:211:in `mon_synchronize'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:262:in `connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_adapters/abstract/connection_pool.rb:567:in `retrieve_connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_handling.rb:113:in `retrieve_connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/connection_handling.rb:87:in `connection'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/attributes.rb:93:in `columns'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/attributes.rb:98:in `columns_hash'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:970:in `block in create_binds'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:967:in `each'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:967:in `partition'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:967:in `create_binds'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:954:in `build_where'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:584:in `where!'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/query_methods.rb:574:in `where'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation/finder_methods.rb:84:in `find_by'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/relation.rb:213:in `find_or_create_by'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activerecord-4.2.2/lib/active_record/querying.rb:6:in `find_or_create_by'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/lib/crono/job.rb:102:in `model'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/lib/crono/job.rb:49:in `load'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/lib/crono/scheduler.rb:11:in `add_job'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/lib/crono/performer_proxy.rb:11:in `every'
12/29/2016 7:52:23 AM/portus/config/cronotab.rb:2:in `<top (required)>'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/polyglot-0.3.3/lib/polyglot.rb:63:in `require'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/polyglot-0.3.3/lib/polyglot.rb:63:in `require'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activesupport-4.2.2/lib/active_support/dependencies.rb:274:in `block in require'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activesupport-4.2.2/lib/active_support/dependencies.rb:240:in `load_dependency'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/activesupport-4.2.2/lib/active_support/dependencies.rb:274:in `require'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/lib/crono/cronotab.rb:7:in `process'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/lib/crono/cli.rb:24:in `run'
12/29/2016 7:52:23 AM/usr/local/bundle/gems/crono-0.9.0/exe/crono:8:in `<top (required)>'
12/29/2016 7:52:23 AM/usr/local/bundle/bin/crono:16:in `load'
12/29/2016 7:52:23 AM/usr/local/bundle/bin/crono:16:in `<main>'
12/29/2016 7:52:23 AM[72] - Worker 1 (pid: 79) booted, phase: 0

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.