Skip to content

Commit 9f77c79

Browse files
committed
Fix Traefik rule in docker-compose template
Signed-off-by: Mriyam Tamuli <[email protected]>
1 parent 8ad9d16 commit 9f77c79

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Site_Docker.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public function generate_docker_compose_yml( array $filters = [] ) {
6666
$nginx['image'] = array( 'name' => 'easyengine/nginx' );
6767
$nginx['depends_on'] = array( 'name' => 'php' );
6868
$nginx['restart'] = $restart_default;
69-
$v_host = in_array( 'wpsubdom', $filters ) ? 'VIRTUAL_HOST=${VIRTUAL_HOST},HostRegexp:{subdomain:.+}.${VIRTUAL_HOST}' : '${VIRTUAL_HOST}';
69+
$v_host = in_array( 'wpsubdom', $filters ) ? 'HostRegexp:{subdomain:.+}.${VIRTUAL_HOST},${VIRTUAL_HOST}' : 'Host:${VIRTUAL_HOST}';
7070

7171
$nginx['labels'] = array(
7272
'label' => array(
@@ -75,7 +75,7 @@ public function generate_docker_compose_yml( array $filters = [] ) {
7575
array( 'name' => 'traefik.protocol=http' ),
7676
array( 'name' => 'traefik.docker.network=site-network' ),
7777
array( 'name' => "traefik.frontend.entryPoints=$frontend_entrypoints" ),
78-
array( 'name' => "traefik.frontend.rule=Host:$v_host" ),
78+
array( 'name' => "traefik.frontend.rule=$v_host" ),
7979
),
8080
);
8181
$nginx['volumes'] = array(

0 commit comments

Comments
 (0)