Skip to content

Commit 6d7eca6

Browse files
committed
Amend server name to create a repo variable in Nginx config.
1 parent b25114f commit 6d7eca6

File tree

1 file changed

+5
-1
lines changed
  • Ansible/ansible_collections/jfrog/platform/roles/artifactory_nginx_ssl/templates

1 file changed

+5
-1
lines changed

Ansible/ansible_collections/jfrog/platform/roles/artifactory_nginx_ssl/templates/artifactory.conf.j2

+5-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,11 @@
1818
## server configuration
1919
server {
2020
listen 443 ssl http2;
21+
{% if artifactory_docker_registry_subdomain %}
22+
server_name ~(?<repo>.+)\.{{ server_name }};
23+
{% else %}
2124
server_name {{ server_name }};
25+
{% endif %}
2226
if ($http_x_forwarded_proto = '') {
2327
set $http_x_forwarded_proto $scheme;
2428
}
@@ -47,4 +51,4 @@
4751
proxy_pass http://artifactory-direct;
4852
}
4953
}
50-
}
54+
}

0 commit comments

Comments
 (0)