-
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
1 parent
2b1ac58
commit 60797da
Showing
3 changed files
with
15 additions
and
10 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,28 @@ | ||
#!/usr/bin/env sh | ||
|
||
platform="$1" | ||
role="$1" | ||
|
||
# App installation tasks on commander node. Runs first | ||
if [ "$platform" = 'commander' ]; then | ||
carburator print terminal info "Executing install script on $platform" | ||
# App installation tasks on a local client node. Runs first | ||
if [ "$role" = 'client' ]; then | ||
carburator print terminal info "Executing install script on $role" | ||
fi | ||
|
||
# App installation tasks on remote worker node. | ||
if [ "$platform" = 'worker' ]; then | ||
carburator print terminal info "Executing install script on $platform" | ||
if [ "$role" = 'worker' ]; then | ||
carburator print terminal info "Executing install script on $role" | ||
fi | ||
|
||
# App installation tasks on remote commander node. | ||
if [ "$role" = 'commander' ]; then | ||
carburator print terminal info "Executing install script on $role" | ||
fi | ||
|
||
# Bash needs bash | ||
if ! carburator fn integration-installed bash; then | ||
if ! carburator has program bash; then | ||
carburator print terminal error \ | ||
"Missing required program bash. Please install it before proceeding." | ||
exit 120 | ||
fi | ||
|
||
# Just a reminder, to figure out where (any) script runs: | ||
# if [[ $(carburator node platform) == 'commander' ]]; then ...... ; fi | ||
# if [[ $(carburator node role) == 'commander' ]]; then ...... ; fi |
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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
name = "bash" | ||
version = "0.1.0" | ||
collection = "Executor" | ||
platforms = ["Commander", "Worker"] | ||
platforms = ["Client", "Commander", "Worker"] | ||
|
||
retry_times = 3 | ||
retry_interval = 10 |