mirror of
https://github.com/cgzirim/seek-tune.git
synced 2025-12-17 08:54:19 +00:00
22 lines
545 B
Bash
22 lines
545 B
Bash
#!/usr/bin/env bash
|
|
|
|
start_server() {
|
|
cd /home/ubuntu/song-recognition
|
|
|
|
export SERVE_HTTPS="true"
|
|
export CERT_KEY="/etc/letsencrypt/live/localport.online/privkey.pem"
|
|
export CERT_FILE="/etc/letsencrypt/live/localport.online/fullchain.pem"
|
|
|
|
go build -tags netgo -ldflags '-s -w' -o app
|
|
sudo setcap CAP_NET_BIND_SERVICE+ep app
|
|
nohup ./app > backend.log 2>&1 &
|
|
}
|
|
|
|
start_client() {
|
|
cd /home/ubuntu/song-recognition/client
|
|
npm install
|
|
npm run build
|
|
nohup serve -s build > client.log 2>&1 &
|
|
}
|
|
|
|
start_server
|