Skip to content

Commit

Permalink
fix init.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
lingdie committed Jun 30, 2023
1 parent 82b3181 commit 54da45f
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions deploy/cloud/scripts/init.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ function sealos_run_frontend {
function mutate_desktop_config() {
# mutate etc/sealos/desktop-config.yaml by using mongodb uri and two random base64 string
sed -i -e "s;<your-mongodb-uri-base64>;$(echo -n "$mongodb_uri" | base64);" etc/sealos/desktop-config.yaml
sed -i -e "s;<your-jwt-secret-base64>;$(cat /dev/urandom | tr -dc 'a-z' | fold -w 64 | head -n 1 | base64);" etc/sealos/desktop-config.yaml
sed -i -e "s;<your-password-salt-base64>;$(cat /dev/urandom | tr -dc 'a-z' | fold -w 64 | head -n 1 | base64);" etc/sealos/desktop-config.yaml
sed -i -e "s;<your-jwt-secret-base64>;$(tr -cd 'a-z0-9' </dev/urandom | head -c64 | base64 -w 0);" etc/sealos/desktop-config.yaml
sed -i -e "s;<your-password-salt-base64>;$(tr -cd 'a-z0-9' </dev/urandom | head -c64 | base64 -w 0);" etc/sealos/desktop-config.yaml
}

function install {
Expand All @@ -95,9 +95,6 @@ function install {
# mock tls
mock_tls $cloudDomain

# add cert for cloud domain
sealos cert --alt-name="$cloudDomain"

# kubectl apply namespace, secret and mongodb
kubectl apply -f manifests/namespace.yaml -f manifests/tls-secret.yaml

Expand Down

0 comments on commit 54da45f

Please sign in to comment.