Merge pull request #8 from Haelnorr/development

Fixes to deployment
This commit is contained in:
2025-02-16 22:59:56 +11:00
committed by GitHub
3 changed files with 3 additions and 3 deletions

View File

@@ -31,7 +31,7 @@ jobs:
run: make test run: make test
- name: Build the binary - name: Build the binary
run: make build run: make build SUFFIX=-staging-$GITHUB_SHA
- name: Deploy to Server - name: Deploy to Server
env: env:

View File

@@ -7,7 +7,7 @@ build:
go mod tidy && \ go mod tidy && \
templ generate && \ templ generate && \
go generate && \ go generate && \
go build -ldflags="-w -s" -o ${BINARY_NAME} go build -ldflags="-w -s" -o ${BINARY_NAME}${SUFFIX}
dev: dev:
templ generate --watch &\ templ generate --watch &\

View File

@@ -13,7 +13,7 @@ COMMIT_HASH=$1
RELEASES_DIR="/home/deploy/releases/staging" RELEASES_DIR="/home/deploy/releases/staging"
DEPLOY_BIN="/home/deploy/staging/projectreshoot" DEPLOY_BIN="/home/deploy/staging/projectreshoot"
SERVICE_NAME="staging.projectreshoot" SERVICE_NAME="staging.projectreshoot"
BINARY_NAME="projectreshoot-${COMMIT_HASH}" BINARY_NAME="projectreshoot-staging-${COMMIT_HASH}"
declare -a PORTS=("3005" "3006" "3007") declare -a PORTS=("3005" "3006" "3007")
# Check if the binary exists # Check if the binary exists