Skip to content

Commit e81c420

Browse files
committed
Update koffan-install.sh
1 parent 3614f82 commit e81c420

1 file changed

Lines changed: 6 additions & 7 deletions

File tree

install/koffan-install.sh

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,28 @@ network_check
1414
update_os
1515

1616
msg_info "Installing Dependencies"
17-
ensure_dependencies build-essential
18-
setup_go
17+
$STD apt install -y build-essential
1918
msg_ok "Installed Dependencies"
2019

20+
setup_go
2121
fetch_and_deploy_gh_release "koffan" "PanSalut/Koffan" "tarball"
2222

2323
msg_info "Building Koffan"
2424
cd /opt/koffan
25-
go build -o koffan main.go
25+
$STD go build -o koffan main.go
2626
msg_ok "Built Koffan"
2727

2828
msg_info "Configuring Koffan"
29-
PASSWORD=$(openssl rand -base64 12)
29+
APP_PASSW=$(openssl rand -base64 12)
3030
mkdir /opt/koffan/data
3131
cat <<EOF >/opt/koffan/data/.env
3232
APP_ENV=production
33-
APP_PASSWORD=${PASSWORD}
33+
APP_PASSWORD=${APP_PASSW}
3434
PORT=3000
3535
DB_PATH=/opt/koffan/data/shopping.db
3636
EOF
37-
3837
cat <<EOF >~/koffan.creds
39-
Password: ${PASSWORD}
38+
Password: ${APP_PASSW}
4039
EOF
4140
msg_ok "Configured Koffan"
4241

0 commit comments

Comments
 (0)