Skip to content

Commit eb391ff

Browse files
authored
Merge pull request #47 from kirtangajjar/custom-docker-compose
Add custom docker-compose support in admin-tools-command
2 parents 6e0fc0d + e449c91 commit eb391ff

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Admin_Tools_Command.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ public function enable( $args, $assoc_args ) {
114114

115115
chdir( $this->site_data->site_fs_path );
116116

117-
$launch = EE::launch( 'docker-compose config --services' );
117+
$launch = EE::launch( \EE_DOCKER::docker_compose_with_custom() . ' config --services' );
118118
$services = explode( PHP_EOL, trim( $launch->stdout ) );
119119
$min_req_services = [ 'nginx', 'php' ];
120120

@@ -135,7 +135,7 @@ public function enable( $args, $assoc_args ) {
135135
$docker_compose_admin = EE\Utils\mustache_render( ADMIN_TEMPLATE_ROOT . '/docker-compose-admin.mustache', $docker_compose_data );
136136
$this->fs->dumpFile( $this->site_data->site_fs_path . '/docker-compose-admin.yml', $docker_compose_admin );
137137

138-
if ( EE::exec( 'docker-compose -f docker-compose.yml -f docker-compose-admin.yml up -d nginx' ) ) {
138+
if ( EE::exec( \EE_DOCKER::docker_compose_with_custom( ['docker-compose-admin.yml'] ) . ' up -d nginx' ) ) {
139139
EE::success( sprintf( 'admin-tools enabled for %s site.', $this->site_data->site_url ) );
140140
$this->site_data->admin_tools = 1;
141141
$this->site_data->save();

0 commit comments

Comments
 (0)