Skip to content

Commit

Permalink
Fix info hook
Browse files Browse the repository at this point in the history
`info` hook script was hardcoding the system domain due to a
misunderstanding how the lookup of exodus values works.
  • Loading branch information
dennisjbell committed Jun 16, 2020
1 parent 112ea9d commit 2f30a53
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions hooks/info
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#!/bin/bash
set -eu
base=$(exodus base_domain)
system_domain=$(lookup --exodus params.system_domain "system.$base")

api_url=https://api.$system_domain
exodus_data="$(lookup --exodus .)"
system_domain="$(echo "$exodus_data" | jq -r '.system_domain // "system.\(.base_domain)"')"
api_domain="$(echo "$exodus_data" | jq -r '.api_domain // "api.\($system_domain)"' --arg system_domain "$system_domain")"
api_url=https://$api_domain
admin=$(exodus admin_username)
password=$(exodus admin_password)

Expand Down

0 comments on commit 2f30a53

Please sign in to comment.