unoverse 0.1.47 → 0.1.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/operator/lib/deploy.sh +6 -1
- package/operator/lib/ground.sh +20 -5
- package/package.json +1 -1
package/operator/lib/deploy.sh
CHANGED
|
@@ -41,7 +41,12 @@ cmd_deploy() {
|
|
|
41
41
|
*) cloud=digitalocean ;;
|
|
42
42
|
esac
|
|
43
43
|
echo ""
|
|
44
|
-
cmd_ground "$([ "$cloud" = "aws" ] && echo aws || echo do)" ||
|
|
44
|
+
cmd_ground "$([ "$cloud" = "aws" ] && echo aws || echo do)" || {
|
|
45
|
+
echo ""
|
|
46
|
+
info "Once that is sorted, run ${BOLD}unoverse deploy${NC} again. It picks up right here."
|
|
47
|
+
echo ""
|
|
48
|
+
exit 1
|
|
49
|
+
}
|
|
45
50
|
echo ""
|
|
46
51
|
info "Your $cloud ground is prefilled. Two commands left:"
|
|
47
52
|
info " cd infra/$cloud && terraform init && terraform apply ${DIM}# creates the server (billable)${NC}"
|
package/operator/lib/ground.sh
CHANGED
|
@@ -18,11 +18,26 @@ _ground_do() {
|
|
|
18
18
|
local out="$dir/terraform.tfvars"
|
|
19
19
|
|
|
20
20
|
if ! command -v doctl >/dev/null 2>&1; then
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
21
|
+
# Offer to install rather than sending the developer away with homework: brew is
|
|
22
|
+
# already on most Macs that got this far. Their yes, their machine, our command.
|
|
23
|
+
if command -v brew >/dev/null 2>&1; then
|
|
24
|
+
local REPLY
|
|
25
|
+
read -r -p " doctl (the DigitalOcean CLI) is needed. Install it now with brew? [Y/n] " REPLY
|
|
26
|
+
if [[ ! "$REPLY" =~ ^[Nn]$ ]]; then
|
|
27
|
+
brew install doctl || { fail "brew install doctl failed"; return 1; }
|
|
28
|
+
ok "doctl installed"
|
|
29
|
+
else
|
|
30
|
+
fail "doctl is needed to continue"
|
|
31
|
+
info " https://docs.digitalocean.com/reference/doctl/how-to/install/"
|
|
32
|
+
return 1
|
|
33
|
+
fi
|
|
34
|
+
else
|
|
35
|
+
fail "doctl is not installed"
|
|
36
|
+
info " brew install doctl (macOS)"
|
|
37
|
+
info " https://docs.digitalocean.com/reference/doctl/how-to/install/"
|
|
38
|
+
info "Then authenticate: doctl auth init"
|
|
39
|
+
return 1
|
|
40
|
+
fi
|
|
26
41
|
fi
|
|
27
42
|
if ! doctl account get >/dev/null 2>&1; then
|
|
28
43
|
fail "doctl is not authenticated"
|
package/package.json
CHANGED