๋์์ run
php
์๋น์ค์ ๋ํด ๋ ๊ฐ์ cronjob์ด ์์ต๋๋ค.
ํ๋์ run
๋ช
๋ น ๋ง ์ฌ๋ฐ๋ฅด๊ฒ ์คํ๋ฉ๋๋ค.
Cannot create container for service php: Conflict. The container name "/folder_php_run_1" is already in use by container {hashhere}. You have to remove (or rename) that container to be able to reuse that name.
Command exited with non-zero status 1
์ด๋ ์๋ง๋ ๊ฐ์ฉ์ฑ์ ํ์ธํ๋ ์๊ฐ๊ณผ ์ค์ ๋ก create
๋ช
๋ น์ ์คํํ๋ ์๊ฐ ์ฌ์ด์ ์ปจํ
์ด๋๊ฐ ์์ฑ๋๊ณ ์์์ ์๋ฏธํฉ๋๋ค. ํด๊ฒฐ์ฑ
์์ด ๋ ์์
์ ์ฝ๊ฐ ๋ค๋ฅธ ์๊ฐ์ ์คํํ๋ ๊ฒ์
๋๋ค (5 ์ด ๊ฐ๊ฒฉ์ด๋ฉด ์ถฉ๋ถํ ์ ์์).
๋ค๋ฅธ tmux ํญ์์ ํ๋ก๊ทธ๋๋ฐ ๋ฐฉ์์ผ๋ก docker-compose up foo bar
& docker-compose up baz bar
ํ์ฌ์ด ๋ฌธ์ ๋ ๋ฐ์ํฉ๋๋ค. ์์ฑ์ ์คํจํ๋ฉด ๊ฒ์ฌ๋ฅผ ๋ค์ ์คํํ๊ณ ์ฐ๊ฒฐ์ ์๋ํด์ผํฉ๋๋ค.
๋งค์ฐ ๊ฐ๋จํ ์ฌํ ์ฌ๋ก :
โค cat docker-compose.yml
version: "2.2"
services:
test:
image: alpine
โค docker-compose run --rm test true
Creating network "test_default" with the default driver
โค docker-compose run --rm test docker-compose run --rm test true &; docker-compose run --rm test true
ERROR: Cannot create container for service test: Conflict. The container name "/test_test_run_1" is already in use by container "76db8705667961966468d66d0667417862ad6edb3fb4c09b95a8ebab4ec36bf8". You have to remove (or rename) that container to be able to reuse that name.
Job 4, 'docker-compose run --rm test doโฆ' has ended
์ ๊ฒฝ์ฐ ๋ฌธ์ ๋ ๋ด๋ถ ์ผ์ ์ ๋ฐ๋ผ ๋ณ๋ ฌ ์์ ์ ํธ๋ฆฌ๊ฑฐํ๋ CI์ ๋๋ค. ์ด ๋๋ฌธ์ ์ผ์ ์ ํดํนํด์ผํ๋ ๊ฒ์ ๋งค์ฐ ์ฌํ ์ผ์ ๋๋ค.