Skip to content

Commit

Permalink
🔨 feat: update the script in order to replace the password of users f…
Browse files Browse the repository at this point in the history
…rom .env file
  • Loading branch information
mostafaghadimi committed Sep 19, 2023
1 parent eef54bf commit 60e6646
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,17 @@

source .env

echo "Start executing the script..."

sed -e "s/\$MINIO_CLICKHOUSE_BACKUP_BUCKET/${MINIO_CLICKHOUSE_BACKUP_BUCKET}/g" \
-e "s/\$MINIO_ACCESS_KEY_ID/${MINIO_ROOT_USER}/g" \
-e "s/\$MINIO_SECRET_ACCESS_KEY/${MINIO_ROOT_PASSWORD}/g" \
config_files/clickhouse/templates/storage-template.xml \
> config_files/clickhouse/etc/clickhouse-server/config.d/storage.xml
> config_files/clickhouse/etc/clickhouse-server/config.d/storage.xml

sed -e "s/\$CLICKHOUSE_ADMIN_USER_PASSWORD/${CLICKHOUSE_ADMIN_USER_PASSWORD}/g" \
-e "s/\$CLICKHOUSE_BUSINESS_INTELLIGENCE_USER_PASSWORD/${CLICKHOUSE_BUSINESS_INTELLIGENCE_USER_PASSWORD}/g" \
config_files/clickhouse/templates/users.xml \
> config_files/clickhouse/etc/clickhouse-server/config.d/users.xml

echo "Successfully executed the script"

0 comments on commit 60e6646

Please sign in to comment.