forked from F1bonacc1/process-compose
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
29 changed files
with
1,674 additions
and
740 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,132 @@ | ||
version: "0.5" | ||
log_level: debug | ||
log_length: 3000 | ||
environment: | ||
- 'ABC=222' | ||
log_location: ./pc.log | ||
shell: | ||
shell_command: "zsh" | ||
shell_argument: "-c" | ||
|
||
processes: | ||
process0: | ||
command: "ls -lFa --color=always" | ||
working_dir: "/" | ||
|
||
process1: | ||
command: "./test_loop.bash ${PROC4}" | ||
availability: | ||
restart: "on_failure" | ||
backoff_seconds: 2 | ||
depends_on: | ||
_process2: | ||
condition: process_completed_successfully | ||
process3: | ||
condition: process_completed | ||
# process4: | ||
# condition: process_completed_successfully | ||
environment: | ||
- 'EXIT_CODE=0' | ||
shutdown: | ||
command: "sleep 2 && pkill -f process1" | ||
signal: 15 | ||
timeout_seconds: 4 | ||
|
||
_process2: | ||
command: "./test_loop.bash process2" | ||
log_location: ./pc.proc2.log | ||
availability: | ||
restart: "on_failure" | ||
# depends_on: | ||
# process3: | ||
# condition: process_completed_successfully | ||
environment: | ||
- 'ABC=2221' | ||
- 'PRINT_ERR=111' | ||
- 'EXIT_CODE=2' | ||
shutdown: | ||
command: "sleep 2 && pkill -f 'test_loop.bash process2'" | ||
signal: 15 | ||
timeout_seconds: 4 | ||
readiness_probe: | ||
http_get: | ||
host: "google.com" | ||
scheme: "https" | ||
initial_delay_seconds: 5 | ||
period_seconds: 5 | ||
timeout_seconds: 2 | ||
success_threshold: 1 | ||
failure_threshold: 3 | ||
|
||
process3: | ||
command: "./test_loop.bash process3" | ||
availability: | ||
restart: "always" | ||
backoff_seconds: 2 | ||
depends_on: | ||
nginx: | ||
condition: process_healthy | ||
|
||
process4: | ||
command: "./test_loop.bash process4-override" | ||
disable_ansi_colors: true | ||
# availability: | ||
# restart: on_failure | ||
environment: | ||
- 'ABC=2221' | ||
- 'EXIT_CODE=4' | ||
readiness_probe: | ||
exec: | ||
command: "ps -ef | grep -v grep | grep process4" | ||
initial_delay_seconds: 5 | ||
period_seconds: 2 | ||
timeout_seconds: 1 | ||
success_threshold: 1 | ||
failure_threshold: 3 | ||
|
||
nginx: | ||
command: "docker run -d --rm -p80:80 --name nginx_test nginx" | ||
# availability: | ||
# restart: on_failure | ||
is_daemon: true | ||
shutdown: | ||
command: "docker stop nginx_test" | ||
signal: 15 | ||
timeout_seconds: 5 | ||
liveness_probe: | ||
exec: | ||
command: "[ $(docker inspect -f '{{.State.Running}}' nginx_test) = 'true' ]" | ||
initial_delay_seconds: 5 | ||
period_seconds: 2 | ||
timeout_seconds: 5 | ||
success_threshold: 1 | ||
failure_threshold: 3 | ||
readiness_probe: | ||
http_get: | ||
host: 127.0.0.1 | ||
path: "/" | ||
port: 80 | ||
initial_delay_seconds: 5 | ||
period_seconds: 10 | ||
timeout_seconds: 5 | ||
success_threshold: 1 | ||
failure_threshold: 3 | ||
availability: | ||
restart: "always" | ||
backoff_seconds: 2 | ||
|
||
pc_log: | ||
command: "tail -f -n100 process-compose-${USER}.log" | ||
working_dir: "/tmp" | ||
environment: | ||
- 'REDACTED=1' | ||
- 'ADDED=2' | ||
depends_on: | ||
process0: | ||
condition: process_completed | ||
|
||
|
||
bat_config: | ||
command: "batcat -f process-compose.yaml" | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.