Skip to content

Commit

Permalink
feat: make container image deployment the default
Browse files Browse the repository at this point in the history
  • Loading branch information
carlalexander committed Dec 24, 2024
1 parent 088fca2 commit 77b2ec3
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Command/Project/InitializeProjectCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -158,10 +158,16 @@ protected function perform()
$this->invoke(InstallPluginCommand::NAME);
}

if ($this->output->confirm('Do you want to deploy this project using a container image?', $this->dockerExecutable->isInstalled())) {
$useContainerImage = $this->output->confirm('Do you want to deploy this project using a container image?');

if ($useContainerImage) {
$this->invoke(CreateDockerfileCommand::NAME, ['--configure-project' => null]);
}

if ($useContainerImage && $this->dockerExecutable->isInstalled()) {
$this->output->warning('Docker wasn\'t detected on this computer. You won\'t be able to deploy this project locally.');
}

if ($this->wpCliExecutable->isInstalled() && $this->wpCliExecutable->isWordPressInstalled() && $this->output->confirm('Do you want to have Ymir scan your plugins and themes and configure your project?')) {
$this->invoke(ConfigureProjectCommand::NAME);
}
Expand Down

0 comments on commit 77b2ec3

Please sign in to comment.