mirror of
https://github.com/project-zot/zot.git
synced 2026-06-16 20:38:08 +08:00
ext: use distribution spec route prefix for extension api
Following the spec defined here https://github.com/opencontainers/distribution-spec/tree/main/extensions Signed-off-by: Shivam Mishra <shimish2@cisco.com>
This commit is contained in:
committed by
Ramkumar Chinchani
parent
c1bf4456d0
commit
36c9631000
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
@@ -11,31 +11,34 @@
|
||||
"level": "debug"
|
||||
},
|
||||
"extensions": {
|
||||
"metrics": {
|
||||
},
|
||||
"metrics": {},
|
||||
"sync": {
|
||||
"credentialsFile": "./examples/sync-auth-filepath.json",
|
||||
"registries": [{
|
||||
"urls": ["https://registry1:5000"],
|
||||
"onDemand": false,
|
||||
"pollInterval": "6h",
|
||||
"tlsVerify": true,
|
||||
"certDir": "/home/user/certs",
|
||||
"maxRetries": 3,
|
||||
"retryDelay": "15m",
|
||||
"content":[
|
||||
{
|
||||
"prefix":"/repo1/repo",
|
||||
"tags":{
|
||||
"regex":"4.*",
|
||||
"semver":true
|
||||
"registries": [
|
||||
{
|
||||
"urls": [
|
||||
"https://registry1:5000"
|
||||
],
|
||||
"onDemand": false,
|
||||
"pollInterval": "6h",
|
||||
"tlsVerify": true,
|
||||
"certDir": "/home/user/certs",
|
||||
"maxRetries": 3,
|
||||
"retryDelay": "15m",
|
||||
"content": [
|
||||
{
|
||||
"prefix": "/repo1/repo",
|
||||
"tags": {
|
||||
"regex": "4.*",
|
||||
"semver": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"prefix": "/repo2/repo"
|
||||
}
|
||||
},
|
||||
{
|
||||
"prefix":"/repo2/repo"
|
||||
}
|
||||
]
|
||||
}]
|
||||
]
|
||||
}
|
||||
]
|
||||
},
|
||||
"search": {
|
||||
"cve": {
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"storage":{
|
||||
"rootDirectory":"/tmp/zot"
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http": {
|
||||
"address":"127.0.0.1",
|
||||
"port":"8080",
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080",
|
||||
"auth": {
|
||||
"bearer": {
|
||||
"realm": "https://auth.myreg.io/auth/token",
|
||||
@@ -14,7 +14,7 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"log":{
|
||||
"level":"debug"
|
||||
"log": {
|
||||
"level": "debug"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot",
|
||||
"commit": true
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"storage":{
|
||||
"rootDirectory":"/tmp/zot",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot",
|
||||
"gc": false,
|
||||
"dedupe": false
|
||||
},
|
||||
"http": {
|
||||
"address":"0.0.0.0",
|
||||
"port":"8080"
|
||||
"address": "0.0.0.0",
|
||||
"port": "8080"
|
||||
},
|
||||
"log":{
|
||||
"level":"debug"
|
||||
"log": {
|
||||
"level": "debug"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
|
||||
@@ -1,30 +1,39 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http": {
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080",
|
||||
"realm": "zot",
|
||||
"accessControl": {
|
||||
"**": {
|
||||
"defaultPolicy": ["read", "create"]
|
||||
},
|
||||
"tmp/**": {
|
||||
"defaultPolicy": ["read", "create", "update"]
|
||||
},
|
||||
"infra/**": {
|
||||
"defaultPolicy": ["read"]
|
||||
},
|
||||
"repos2/repo": {
|
||||
"defaultPolicy": ["read"]
|
||||
}
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http": {
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080",
|
||||
"realm": "zot",
|
||||
"accessControl": {
|
||||
"**": {
|
||||
"defaultPolicy": [
|
||||
"read",
|
||||
"create"
|
||||
]
|
||||
},
|
||||
"tmp/**": {
|
||||
"defaultPolicy": [
|
||||
"read",
|
||||
"create",
|
||||
"update"
|
||||
]
|
||||
},
|
||||
"infra/**": {
|
||||
"defaultPolicy": [
|
||||
"read"
|
||||
]
|
||||
},
|
||||
"repos2/repo": {
|
||||
"defaultPolicy": [
|
||||
"read"
|
||||
]
|
||||
}
|
||||
},
|
||||
"log": {
|
||||
"level": "debug"
|
||||
}
|
||||
},
|
||||
"log": {
|
||||
"level": "debug"
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,27 +1,27 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"storage":{
|
||||
"rootDirectory":"/tmp/zot"
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http": {
|
||||
"address":"127.0.0.1",
|
||||
"port":"8080",
|
||||
"realm":"zot",
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080",
|
||||
"realm": "zot",
|
||||
"tls": {
|
||||
"cert":"test/data/server.cert",
|
||||
"key":"test/data/server.key"
|
||||
"cert": "test/data/server.cert",
|
||||
"key": "test/data/server.key"
|
||||
},
|
||||
"auth": {
|
||||
"ldap": {
|
||||
"address":"ldap.example.org",
|
||||
"port":389,
|
||||
"startTLS":false,
|
||||
"baseDN":"ou=Users,dc=example,dc=org",
|
||||
"userAttribute":"uid",
|
||||
"bindDN":"cn=ldap-searcher,ou=Users,dc=example,dc=org",
|
||||
"bindPassword":"ldap-searcher-password",
|
||||
"skipVerify":false,
|
||||
"subtreeSearch":true
|
||||
"address": "ldap.example.org",
|
||||
"port": 389,
|
||||
"startTLS": false,
|
||||
"baseDN": "ou=Users,dc=example,dc=org",
|
||||
"userAttribute": "uid",
|
||||
"bindDN": "cn=ldap-searcher,ou=Users,dc=example,dc=org",
|
||||
"bindPassword": "ldap-searcher-password",
|
||||
"skipVerify": false,
|
||||
"subtreeSearch": true
|
||||
},
|
||||
"htpasswd": {
|
||||
"path": "test/data/htpasswd"
|
||||
@@ -30,9 +30,9 @@
|
||||
},
|
||||
"allowReadAccess": false
|
||||
},
|
||||
"log":{
|
||||
"level":"debug",
|
||||
"output":"/tmp/zot.log",
|
||||
"log": {
|
||||
"level": "debug",
|
||||
"output": "/tmp/zot.log",
|
||||
"audit": "/tmp/zot-audit.log"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
distspecversion: 1.0.1
|
||||
distspecversion: 1.0.1-dev
|
||||
http:
|
||||
address: 127.0.0.1
|
||||
allowreadaccess: false
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot",
|
||||
"gc": true,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot",
|
||||
"gc": true,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot",
|
||||
"dedupe": true,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot",
|
||||
"dedupe": true,
|
||||
|
||||
+64
-18
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
@@ -17,44 +17,91 @@
|
||||
"**": {
|
||||
"policies": [
|
||||
{
|
||||
"users": ["charlie"],
|
||||
"actions": ["read", "create", "update"]
|
||||
"users": [
|
||||
"charlie"
|
||||
],
|
||||
"actions": [
|
||||
"read",
|
||||
"create",
|
||||
"update"
|
||||
]
|
||||
}
|
||||
],
|
||||
"defaultPolicy": ["read", "create"]
|
||||
"defaultPolicy": [
|
||||
"read",
|
||||
"create"
|
||||
]
|
||||
},
|
||||
"tmp/**": {
|
||||
"defaultPolicy": ["read", "create", "update"]
|
||||
"defaultPolicy": [
|
||||
"read",
|
||||
"create",
|
||||
"update"
|
||||
]
|
||||
},
|
||||
"infra/**": {
|
||||
"policies": [
|
||||
{
|
||||
"users": ["alice", "bob"],
|
||||
"actions": ["create", "read", "update", "delete"]
|
||||
"users": [
|
||||
"alice",
|
||||
"bob"
|
||||
],
|
||||
"actions": [
|
||||
"create",
|
||||
"read",
|
||||
"update",
|
||||
"delete"
|
||||
]
|
||||
},
|
||||
{
|
||||
"users": ["mallory"],
|
||||
"actions": ["create", "read"]
|
||||
"users": [
|
||||
"mallory"
|
||||
],
|
||||
"actions": [
|
||||
"create",
|
||||
"read"
|
||||
]
|
||||
}
|
||||
],
|
||||
"defaultPolicy": ["read"]
|
||||
"defaultPolicy": [
|
||||
"read"
|
||||
]
|
||||
},
|
||||
"repos2/repo": {
|
||||
"policies": [
|
||||
{
|
||||
"users": ["charlie"],
|
||||
"actions": ["read", "create"]
|
||||
"users": [
|
||||
"charlie"
|
||||
],
|
||||
"actions": [
|
||||
"read",
|
||||
"create"
|
||||
]
|
||||
},
|
||||
{
|
||||
"users": ["mallory"],
|
||||
"actions": ["create", "read"]
|
||||
"users": [
|
||||
"mallory"
|
||||
],
|
||||
"actions": [
|
||||
"create",
|
||||
"read"
|
||||
]
|
||||
}
|
||||
],
|
||||
"defaultPolicy": ["read"]
|
||||
"defaultPolicy": [
|
||||
"read"
|
||||
]
|
||||
},
|
||||
"adminPolicy": {
|
||||
"users": ["admin"],
|
||||
"actions": ["read", "create", "update", "delete"]
|
||||
"users": [
|
||||
"admin"
|
||||
],
|
||||
"actions": [
|
||||
"read",
|
||||
"create",
|
||||
"update",
|
||||
"delete"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -63,4 +110,3 @@
|
||||
"output": "/tmp/zot.log"
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion": "1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/zot",
|
||||
"storageDriver": {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
|
||||
+64
-56
@@ -1,68 +1,76 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"storage":{
|
||||
"rootDirectory":"/tmp/zot"
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http":{
|
||||
"address":"127.0.0.1",
|
||||
"port":"8080"
|
||||
"http": {
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080"
|
||||
},
|
||||
"log":{
|
||||
"level":"debug"
|
||||
"log": {
|
||||
"level": "debug"
|
||||
},
|
||||
"extensions":{
|
||||
"extensions": {
|
||||
"sync": {
|
||||
"enable": true,
|
||||
"credentialsFile": "./examples/sync-auth-filepath.json",
|
||||
"registries": [{
|
||||
"urls": ["https://registry1:5000"],
|
||||
"onDemand": false,
|
||||
"pollInterval": "6h",
|
||||
"tlsVerify": true,
|
||||
"certDir": "/home/user/certs",
|
||||
"maxRetries": 3,
|
||||
"retryDelay": "5m",
|
||||
"onlySigned": true,
|
||||
"content":[
|
||||
{
|
||||
"prefix":"/repo1/repo",
|
||||
"tags":{
|
||||
"regex":"4.*",
|
||||
"semver":true
|
||||
"registries": [
|
||||
{
|
||||
"urls": [
|
||||
"https://registry1:5000"
|
||||
],
|
||||
"onDemand": false,
|
||||
"pollInterval": "6h",
|
||||
"tlsVerify": true,
|
||||
"certDir": "/home/user/certs",
|
||||
"maxRetries": 3,
|
||||
"retryDelay": "5m",
|
||||
"onlySigned": true,
|
||||
"content": [
|
||||
{
|
||||
"prefix": "/repo1/repo",
|
||||
"tags": {
|
||||
"regex": "4.*",
|
||||
"semver": true
|
||||
}
|
||||
},
|
||||
{
|
||||
"prefix": "/repo1/repo",
|
||||
"destination": "/repo",
|
||||
"stripPrefix": true
|
||||
},
|
||||
{
|
||||
"prefix": "/repo2/repo"
|
||||
}
|
||||
},
|
||||
{
|
||||
"prefix":"/repo1/repo",
|
||||
"destination": "/repo",
|
||||
"stripPrefix": true
|
||||
},
|
||||
{
|
||||
"prefix":"/repo2/repo"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"urls": ["https://registry2:5000", "https://registry3:5000"],
|
||||
"pollInterval": "12h",
|
||||
"tlsVerify": false,
|
||||
"onDemand": false,
|
||||
"content":[
|
||||
{
|
||||
"prefix":"/repo2",
|
||||
"tags":{
|
||||
"semver":true
|
||||
]
|
||||
},
|
||||
{
|
||||
"urls": [
|
||||
"https://registry2:5000",
|
||||
"https://registry3:5000"
|
||||
],
|
||||
"pollInterval": "12h",
|
||||
"tlsVerify": false,
|
||||
"onDemand": false,
|
||||
"content": [
|
||||
{
|
||||
"prefix": "/repo2",
|
||||
"tags": {
|
||||
"semver": true
|
||||
}
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"urls": ["https://docker.io/library"],
|
||||
"onDemand": true,
|
||||
"tlsVerify": true,
|
||||
"maxRetries": 6,
|
||||
"retryDelay": "5m"
|
||||
}
|
||||
]
|
||||
]
|
||||
},
|
||||
{
|
||||
"urls": [
|
||||
"https://docker.io/library"
|
||||
],
|
||||
"onDemand": true,
|
||||
"tlsVerify": true,
|
||||
"maxRetries": 6,
|
||||
"retryDelay": "5m"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"storage":{
|
||||
"rootDirectory":"/tmp/zot"
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http": {
|
||||
"address":"127.0.0.1",
|
||||
"port":"8080"
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080"
|
||||
},
|
||||
"log":{
|
||||
"level":"debug"
|
||||
"log": {
|
||||
"level": "debug"
|
||||
}
|
||||
}
|
||||
|
||||
+10
-10
@@ -1,18 +1,18 @@
|
||||
{
|
||||
"distSpecVersion":"1.0.1",
|
||||
"storage":{
|
||||
"rootDirectory":"/tmp/zot"
|
||||
"distSpecVersion": "1.0.1-dev",
|
||||
"storage": {
|
||||
"rootDirectory": "/tmp/zot"
|
||||
},
|
||||
"http": {
|
||||
"address":"127.0.0.1",
|
||||
"port":"8080",
|
||||
"realm":"zot",
|
||||
"address": "127.0.0.1",
|
||||
"port": "8080",
|
||||
"realm": "zot",
|
||||
"tls": {
|
||||
"cert":"test/data/server.cert",
|
||||
"key":"test/data/server.key"
|
||||
"cert": "test/data/server.cert",
|
||||
"key": "test/data/server.key"
|
||||
}
|
||||
},
|
||||
"log":{
|
||||
"level":"debug"
|
||||
"log": {
|
||||
"level": "debug"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user