diff --git a/files/groovy/create_repo_docker_group.groovy b/files/groovy/create_repo_docker_group.groovy index 6b144a2..b64c2c5 100644 --- a/files/groovy/create_repo_docker_group.groovy +++ b/files/groovy/create_repo_docker_group.groovy @@ -9,7 +9,6 @@ configuration = new Configuration( online: true, attributes: [ docker: [ - httpPort: parsed_args.http_port, v1Enabled : parsed_args.v1_enabled ], group: [ @@ -23,6 +22,10 @@ configuration = new Configuration( ] ) +if (parsed_args.http_port) { + configuration.attributes['docker']['httpPort'] = parsed_args.http_port +} + def existingRepository = repository.getRepositoryManager().get(parsed_args.name) if (existingRepository != null) { diff --git a/files/groovy/create_repo_docker_hosted.groovy b/files/groovy/create_repo_docker_hosted.groovy index d68b2a2..d78c822 100644 --- a/files/groovy/create_repo_docker_hosted.groovy +++ b/files/groovy/create_repo_docker_hosted.groovy @@ -9,7 +9,6 @@ configuration = new Configuration( online: true, attributes: [ docker: [ - httpPort: parsed_args.http_port, v1Enabled : parsed_args.v1_enabled ], storage: [ @@ -20,6 +19,10 @@ configuration = new Configuration( ] ) +if (parsed_args.http_port) { + configuration.attributes['docker']['httpPort'] = parsed_args.http_port +} + def existingRepository = repository.getRepositoryManager().get(parsed_args.name) if (existingRepository != null) { diff --git a/files/groovy/create_repo_docker_proxy.groovy b/files/groovy/create_repo_docker_proxy.groovy index edab0fc..e4a8abd 100644 --- a/files/groovy/create_repo_docker_proxy.groovy +++ b/files/groovy/create_repo_docker_proxy.groovy @@ -9,7 +9,6 @@ configuration = new Configuration( online: true, attributes: [ docker: [ - httpPort: parsed_args.http_port, v1Enabled : parsed_args.v1_enabled ], proxy: [ @@ -36,6 +35,10 @@ configuration = new Configuration( ] ) +if (parsed_args.http_port) { + configuration.attributes['docker']['httpPort'] = parsed_args.http_port +} + def existingRepository = repository.getRepositoryManager().get(parsed_args.name) if (existingRepository != null) {