forked from OpenCloud/opencloud

13 changed files with 81 additions and 17 deletions
@ -0,0 +1,50 @@
|
||||
maintainer = { |
||||
name = "Till Wegmueller" |
||||
email = "till.wegmueller@openflowlabs.com" |
||||
} |
||||
|
||||
image "builders/registry" { |
||||
base = "builders/golang" |
||||
env = { |
||||
PATH = "/usr/sbin:/sbin:/usr/bin" |
||||
} |
||||
|
||||
action "Download Registry From Git" { |
||||
cmd = "git clone https://github.com/docker/distribution.git /root/distribution" |
||||
} |
||||
|
||||
action "Get Custom main.go file" { |
||||
cmd = "wget -O /root/distribution/cmd/registry/main.go https://gist.githubusercontent.com/Toasterson/62b19dd85e4151561081391fa9987f51/raw/1c0e14a7480b0a29f469334b889969af9a48b497/main.go" |
||||
} |
||||
|
||||
action "Build the registry binary" { |
||||
cmd = "go build -o /dest/registry /root/distribution/cmd/registry/main.go" |
||||
} |
||||
} |
||||
|
||||
image "aurora-opencloud/registry" { |
||||
base = "openindiana/hipster" |
||||
env = { |
||||
PATH = "/usr/sbin:/sbin:/usr/bin" |
||||
} |
||||
|
||||
copy "Copy registry binary from builder image" { |
||||
source_image = "builders/registry" |
||||
path = "/dest/registry" |
||||
target = "/registry" |
||||
} |
||||
|
||||
copy "Copy registry config from builder image" { |
||||
source_image = "builders/registry" |
||||
path = "/root/distribution/cmd/registry/config-example.yml" |
||||
target = "/registry_config.yml" |
||||
} |
||||
|
||||
volume "/var/lib/registry" { |
||||
name = "Registry layer directory" |
||||
} |
||||
|
||||
expose = [ "5000" ] |
||||
workdir = "/" |
||||
cmd = ["/registry", "--config", "/registry_config.yml" ] |
||||
} |
Loading…
Reference in new issue