github.com/misfo/deis@v1.0.1-0.20141111224634-e0eee0392b8a/registry/templates/config.yml (about) 1 # All other flavors inherit the `common' config snippet 2 common: &common 3 # Default log level is info 4 loglevel: _env:LOGLEVEL:info 5 # Enable the debugging /_versions endpoint 6 debug_versions: _env:DEBUG_VERSIONS:false 7 # By default, the registry acts standalone (eg: doesn't query the index) 8 standalone: _env:STANDALONE:true 9 # The default endpoint to use (if NOT standalone) is index.docker.io 10 index_endpoint: _env:INDEX_ENDPOINT:https://index.docker.io 11 # Storage redirect is disabled 12 storage_redirect: _env:STORAGE_REDIRECT 13 # Token auth is enabled (if NOT standalone) 14 disable_token_auth: _env:DISABLE_TOKEN_AUTH 15 # No priv key 16 privileged_key: _env:PRIVILEGED_KEY 17 # No search backend 18 search_backend: _env:SEARCH_BACKEND 19 # SQLite search backend 20 sqlalchemy_index_database: _env:SQLALCHEMY_INDEX_DATABASE:sqlite:////tmp/docker-registry.db 21 22 # Mirroring is not enabled 23 mirroring: 24 source: _env:MIRROR_SOURCE # https://registry-1.docker.io 25 source_index: _env:MIRROR_SOURCE_INDEX # https://index.docker.io 26 tags_cache_ttl: _env:MIRROR_TAGS_CACHE_TTL:172800 # seconds 27 28 cache: 29 host: {{ or (.deis_cache_host) "~" }} 30 port: {{ or (.deis_cache_port) "~" }} 31 password: _env:CACHE_REDIS_PASSWORD 32 db: 1 33 34 # Enabling LRU cache for small files 35 # This speeds up read/write on small files 36 # when using a remote storage backend (like S3). 37 # cache_lru: 38 # host: _env:CACHE_LRU_REDIS_HOST:localhost 39 # port: _env:CACHE_LRU_REDIS_PORT:6379 40 # db: 0 41 # password: _env:CACHE_LRU_REDIS_PASSWORD 42 43 # Enabling these options makes the Registry send an email on each code Exception 44 {{ if .deis_registry_smtpHost }} 45 email_exceptions: 46 smtp_host: {{ or (.deis_registry_smtpHost) "" }} 47 smtp_port: {{ or (.deis_registry_smtpPort) "25" }} 48 smtp_login: {{ or (.deis_registry_smtpLogin) "" }} 49 smtp_password: {{ or (.deis_registry_smtpPassword) "" }} 50 smtp_secure: bool({{ or (.deis_registry_smtpSecure) "false" }}) 51 from_addr: {{ or (.deis_registry_smtpFrom) "docker-registry@localdomain.local" }} 52 to_addr: {{ or (.deis_registry_smtpTo) "noise+dockerregistry@localdomain.local" }} 53 {{ end }} 54 55 # Enable bugsnag (set the API key) 56 bugsnag: _env:BUGSNAG 57 58 # CORS support is not enabled by default 59 cors: 60 origins: _env:CORS_ORIGINS:["null"] 61 methods: _env:CORS_METHODS 62 headers: _env:CORS_HEADERS:[Content-Type] 63 expose_headers: _env:CORS_EXPOSE_HEADERS 64 supports_credentials: _env:CORS_SUPPORTS_CREDENTIALS 65 max_age: _env:CORS_MAX_AGE 66 send_wildcard: _env:CORS_SEND_WILDCARD 67 always_send: _env:CORS_ALWAYS_SEND 68 automatic_options: _env:CORS_AUTOMATIC_OPTIONS 69 vary_header: _env:CORS_VARY_HEADER 70 resources: _env:CORS_RESOURCES 71 72 local: &local 73 <<: *common 74 storage: local 75 storage_path: /data 76 77 78 s3: &s3 79 <<: *common 80 storage: s3 81 s3_region: {{ or (.deis_registry_s3region) "" }} 82 s3_bucket: {{ or (.deis_registry_s3bucket) "" }} 83 boto_bucket: {{ or (.deis_registry_s3bucket) "" }} 84 storage_path: {{ or (.deis_registry_s3path) "/registry" }} 85 s3_encrypt: bool({{ or (.deis_registry_s3encrypt) "true" }}) 86 s3_secure: bool({{ or (.deis_registry_s3secure) "true" }}) 87 s3_access_key: {{ or (.deis_registry_s3accessKey) "" }} 88 s3_secret_key: {{ or (.deis_registry_s3secretKey) "" }} 89 90 # Ceph Object Gateway Configuration 91 # See http://ceph.com/docs/master/radosgw/ for details on installing this service. 92 ceph-s3: &ceph-s3 93 <<: *common 94 storage: s3 95 s3_region: ~ 96 s3_bucket: {{ .deis_registry_bucketName }} 97 s3_encrypt: false 98 s3_secure: false 99 storage_path: /registry 100 s3_access_key: {{ .deis_store_gateway_accessKey }} 101 s3_secret_key: {{ .deis_store_gateway_secretKey }} 102 boto_bucket: {{ .deis_registry_bucketName }} 103 boto_host: {{ .deis_store_gateway_host }} 104 boto_port: {{ .deis_store_gateway_port }} 105 boto_debug: 0 106 boto_calling_format: boto.s3.connection.OrdinaryCallingFormat 107 108 # Google Cloud Storage Configuration 109 # See: 110 # https://developers.google.com/storage/docs/reference/v1/getting-startedv1#keys 111 # for details on access and secret keys. 112 gcs: 113 <<: *common 114 storage: gcs 115 boto_bucket: _env:GCS_BUCKET 116 storage_path: _env:STORAGE_PATH:/registry 117 gs_secure: _env:GCS_SECURE:true 118 gs_access_key: _env:GCS_KEY 119 gs_secret_key: _env:GCS_SECRET 120 # OAuth 2.0 authentication with the storage. 121 # oauth2 can be set to true or false. If it is set to true, gs_access_key, 122 # gs_secret_key and gs_secure are not needed. 123 # Client ID and Client Secret must be set into OAUTH2_CLIENT_ID and 124 # OAUTH2_CLIENT_SECRET environment variables. 125 # See: https://developers.google.com/accounts/docs/OAuth2. 126 oauth2: _env:GCS_OAUTH2:false 127 128 # This flavor is for storing images in Openstack Swift 129 swift: &swift 130 <<: *common 131 storage: swift 132 storage_path: _env:STORAGE_PATH:/registry 133 # keystone authorization 134 swift_authurl: {{ or (.deis_registry_swiftAuthURL) "" }} 135 swift_container: {{ or (.deis_registry_swiftContainer) "" }} 136 swift_user: {{ or (.deis_registry_swiftUser) "" }} 137 swift_password: {{ or (.deis_registry_swiftPassword) "" }} 138 swift_tenant_name: {{ or (.deis_registry_swiftTenantName) "" }} 139 swift_region_name: {{ or (.deis_registry_swiftRegionName) "" }} 140 141 # This flavor stores the images in Glance (to integrate with openstack) 142 # See also: https://github.com/dotcloud/openstack-docker 143 glance: &glance 144 <<: *common 145 storage: glance 146 storage_alternate: _env:GLANCE_STORAGE_ALTERNATE:file 147 storage_path: _env:STORAGE_PATH:/tmp/registry 148 149 openstack: 150 <<: *glance 151 152 # This flavor stores the images in Glance (to integrate with openstack) 153 # and tags in Swift. 154 glance-swift: &glance-swift 155 <<: *swift 156 storage: glance 157 storage_alternate: swift 158 159 openstack-swift: 160 <<: *glance-swift 161 162 elliptics: 163 <<: *common 164 storage: elliptics 165 elliptics_nodes: _env:ELLIPTICS_NODES 166 elliptics_wait_timeout: _env:ELLIPTICS_WAIT_TIMEOUT:60 167 elliptics_check_timeout: _env:ELLIPTICS_CHECK_TIMEOUT:60 168 elliptics_io_thread_num: _env:ELLIPTICS_IO_THREAD_NUM:2 169 elliptics_net_thread_num: _env:ELLIPTICS_NET_THREAD_NUM:2 170 elliptics_nonblocking_io_thread_num: _env:ELLIPTICS_NONBLOCKING_IO_THREAD_NUM:2 171 elliptics_groups: _env:ELLIPTICS_GROUPS 172 elliptics_verbosity: _env:ELLIPTICS_VERBOSITY:4 173 elliptics_logfile: _env:ELLIPTICS_LOGFILE:/dev/stderr 174 elliptics_addr_family: _env:ELLIPTICS_ADDR_FAMILY:2 175 176 # This is the default configuration when no flavor is specified 177 dev: &dev 178 <<: *local 179 loglevel: _env:LOGLEVEL:debug 180 search_backend: _env:SEARCH_BACKEND:sqlalchemy 181 182 # This flavor is used by unit tests 183 test: 184 <<: *dev 185 index_endpoint: https://indexstaging-docker.dotcloud.com 186 standalone: true 187 storage_path: _env:STORAGE_PATH:./tmp/test 188 189 # To specify another flavor, set the environment variable SETTINGS_FLAVOR 190 # $ export SETTINGS_FLAVOR=prod 191 prod: 192 <<: *s3 193 storage_path: _env:STORAGE_PATH:/prod 194 195 # Flavor used by deis 196 deis: 197 {{ if .deis_registry_s3accessKey }}<<: *s3 198 {{ else if .deis_registry_swiftAuthURL }} <<: *openstack-swift 199 {{ else }} <<: *ceph-s3 200 {{ end }}