Skip to content

Commit

Permalink
master: moving beer table creation into demo scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
grove-mountain committed Apr 4, 2019
1 parent b135772 commit c1e537a
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
18 changes: 16 additions & 2 deletions vault/azure_secret_sprawl_webinar/1_azure_dyn_db.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,23 @@
. env.sh

green "Enable the Azure auth method"
pe "vault auth enable azure"
green "Create the source table used in the examples below"

cat << EOF
mysql -h \${MYSQL_HOST_FULL}
-D \${MYSQL_DATABASE}
-u \${MYSQL_VAULT_USER}@\${MYSQL_HOST}
--password=\${MYSQL_VAULT_PASSWORD} < ~/hc-demos/vault/azure_secret_sprawl_webinar/terraform/files/create_beer_table.sql
EOF
p

mysql -h ${MYSQL_HOST_FULL} \
-D ${MYSQL_DATABASE} \
-u ${MYSQL_VAULT_USER}@${MYSQL_HOST} \
--password=${MYSQL_VAULT_PASSWORD} < ~/hc-demos/vault/azure_secret_sprawl_webinar/terraform/files/create_beer_table.sql


green "Enable the Azure auth method"
pe "vault auth enable azure"

green "Azure auth needs a service principle to actually verify logins from other service principles"
cat << EOF
Expand Down
3 changes: 0 additions & 3 deletions vault/azure_secret_sprawl_webinar/terraform/files/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,3 @@ echo "Vault installation complete."

echo "Installing code repo for demo"
git clone https://github.com/grove-mountain/hc-demos.git
export MYSQL_HOST_FULL=${MYSQL_HOST}.mysql.database.azure.com

mysql -h ${MYSQL_HOST_FULL} -D ${MYSQL_DATABASE} -u ${MYSQL_VAULT_USER}@${MYSQL_HOST} --password=${MYSQL_VAULT_PASSWORD} < hc-demos/vault/azure_secret_sprawl_webinar/terraform/files/create_beer_table.sql

0 comments on commit c1e537a

Please sign in to comment.