docker-run without run if image already exists
This commit is contained in:
parent
e4b536e439
commit
060b2ec0ff
|
@ -474,12 +474,11 @@ gulp.task('docker-start', async () => {
|
|||
gulp.task('docker-run', async () => {
|
||||
try {
|
||||
await execP('docker image inspect -f "{{json .Id}}" dblocal');
|
||||
await execP('docker run -d --name dblocal -p 3306:3306 dblocal');
|
||||
await runSequenceP('docker-wait');
|
||||
} catch (err) {
|
||||
await runSequenceP('docker-image');
|
||||
}
|
||||
|
||||
await execP('docker run -d --name dblocal -p 3306:3306 dblocal');
|
||||
await runSequenceP('docker-wait');
|
||||
});
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue