Skip to content

Commit

Permalink
fix: even more hobby upgrade fangling
Browse files Browse the repository at this point in the history
  • Loading branch information
pauldambra committed Oct 10, 2024
1 parent b2db871 commit 52a7d64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions bin/upgrade-hobby
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
set -e

echo "Upgrading PostHog. This will cause a few minutes of downtime."
read -r -p "Do you want to upgarde PostHog? [y/N] " response
read -r -p "Do you want to upgrade PostHog? [y/N] " response
if [[ "$response" =~ ^([yY][eE][sS]|[yY])+$ ]]
then
echo "OK!"
Expand Down Expand Up @@ -69,7 +69,7 @@ else
EXISTING_KEY=$(grep "ENCRYPTION_SALT_KEYS" .env | cut -d '=' -f2)

# Check if the existing key is in the correct format (32 bytes base64url)
if [[ ! $EXISTING_KEY =~ ^[A-Za-z0-9_-]{43}$ ]]; then
if [[ ! $EXISTING_KEY =~ ^[A-Za-z0-9_-]{32}$ ]]; then
echo "ENCRYPTION_SALT_KEYS is not in the correct fernet format and will not work"
echo "🛑 Stop this script and do not proceed"
echo "remove ENCRYPTION_SALT_KEYS from .env and try again"
Expand Down

0 comments on commit 52a7d64

Please sign in to comment.