-
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
6 changed files
with
23 additions
and
66 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
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,9 @@ | ||
#!/bin/sh | ||
|
||
# test for the presence of the openssl command, install via nix-shell if not found | ||
if ! command -v openssl &> /dev/null | ||
then | ||
nix-shell -p openssl --command "bash test.sh" | ||
else | ||
# build the latest image | ||
nix build | ||
docker load < result | ||
# Generate random keys and salts | ||
export WORDPRESS_AUTH_KEY=$(openssl rand -base64 32) | ||
export WORDPRESS_SECURE_AUTH_KEY=$(openssl rand -base64 32) | ||
export WORDPRESS_LOGGED_IN_KEY=$(openssl rand -base64 32) | ||
export WORDPRESS_NONCE_KEY=$(openssl rand -base64 32) | ||
export WORDPRESS_AUTH_SALT=$(openssl rand -base64 32) | ||
export WORDPRESS_SECURE_AUTH_SALT=$(openssl rand -base64 32) | ||
export WORDPRESS_LOGGED_IN_SALT=$(openssl rand -base64 32) | ||
export WORDPRESS_NONCE_SALT=$(openssl rand -base64 32) | ||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" # Get the directory of the script | ||
|
||
# Run docker-compose | ||
docker-compose up | ||
fi | ||
nix build | ||
docker load < result | ||
|
||
# Run docker-compose | ||
cd "$SCRIPT_DIR" && docker-compose up |
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