Skip to content

Commit e45dfa8

Browse files
committed
Add no cache option when rebuilding
1 parent d0b4509 commit e45dfa8

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

ProcessMaker/Console/Commands/BuildScriptExecutors.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,15 +160,17 @@ public function buildExecutor()
160160
$this->info('Building the docker executor');
161161

162162
$image = $scriptExecutor->dockerImageName();
163+
$cacheArg = $this->option('rebuild') ? '--no-cache ' : '';
163164
$command = Docker::command() .
164-
" build --build-arg SDK_DIR=./sdk -t {$image} -f {$packagePath}/Dockerfile.custom {$packagePath}";
165+
" build {$cacheArg}--build-arg SDK_DIR=./sdk -t {$image} -f {$packagePath}/Dockerfile.custom {$packagePath}";
165166

166167
$buildArgs = $this->getBuildArgs();
167168

168169
foreach ($buildArgs as $buildArg) {
169170
$command .= ' ' . $buildArg;
170171
}
171172

173+
$this->info("Running command: $command");
172174
$this->execCommand($command);
173175

174176
$isNayra = $scriptExecutor->language === Base::NAYRA_LANG;

0 commit comments

Comments
 (0)