| @@ 317-333 (lines=17) @@ | ||
| 314 | * |
|
| 315 | * @return void |
|
| 316 | */ |
|
| 317 | public function dockerMagento(array $args) |
|
| 318 | { |
|
| 319 | ||
| 320 | // if not argument has been passed, execute the info command |
|
| 321 | if (sizeof($args) === 0) { |
|
| 322 | $args = array('help'); |
|
| 323 | } |
|
| 324 | ||
| 325 | // start syncing the sources |
|
| 326 | $this->taskExec('docker') |
|
| 327 | ->arg('exec') |
|
| 328 | ->arg($this->getTargetContainer()) |
|
| 329 | ->arg('bash') |
|
| 330 | ->arg('-c') |
|
| 331 | ->arg(sprintf('cd %s && chmod +x bin/magento && bin/magento %s', $this->getDockerMagentoRootDir(), implode(' ', $args))) |
|
| 332 | ->run(); |
|
| 333 | } |
|
| 334 | ||
| 335 | /** |
|
| 336 | * Invokes the passed Composer command inside the Magento root directory of the docker container. |
|
| @@ 342-358 (lines=17) @@ | ||
| 339 | * |
|
| 340 | * @return void |
|
| 341 | */ |
|
| 342 | public function dockerComposer(array $args) |
|
| 343 | { |
|
| 344 | ||
| 345 | // if not argument has been passed, execute the info command |
|
| 346 | if (sizeof($args) === 0) { |
|
| 347 | $args = array('help'); |
|
| 348 | } |
|
| 349 | ||
| 350 | // start syncing the sources |
|
| 351 | $this->taskExec('docker') |
|
| 352 | ->arg('exec') |
|
| 353 | ->arg($this->getTargetContainer()) |
|
| 354 | ->arg('bash') |
|
| 355 | ->arg('-c') |
|
| 356 | ->arg(sprintf('cd %s && composer %s', $this->getDockerMagentoRootDir(), implode(' ', $args))) |
|
| 357 | ->run(); |
|
| 358 | } |
|
| 359 | ||
| 360 | /** |
|
| 361 | * The complete build process. |
|