Compare commits

..

No commits in common. "3d2a4209fc6f0ce88ecaa5eb816a9b8ceab7a471" and "1d35245534d9143e6e8adfd23a5483200f3002c3" have entirely different histories.

3 changed files with 8 additions and 14 deletions

View File

@ -5,7 +5,7 @@
set -e set -e
BASE_URL="http://localhost:9877" BASE_URL="http://localhost:9876"
BLOSSOM_URL="http://localhost:8081" BLOSSOM_URL="http://localhost:8081"
GRAFANA_URL="http://localhost:3000" GRAFANA_URL="http://localhost:3000"
PROMETHEUS_URL="http://localhost:9090" PROMETHEUS_URL="http://localhost:9090"

View File

@ -188,13 +188,10 @@ if [ "$SKIP_BUILD" = false ]; then
# Install Go dependencies # Install Go dependencies
go mod download go mod download
# Create bin directory if it doesn't exist
mkdir -p bin
# Build binary # Build binary
go build -o bin/gateway \ go build -o bin/gateway \
-ldflags "-X main.version=$(git describe --tags --always 2>/dev/null || echo 'dev') -X main.buildTime=$(date -u +%Y-%m-%dT%H:%M:%SZ) -s -w" \ -ldflags "-X main.version=$(git describe --tags --always 2>/dev/null || echo 'dev') -X main.buildTime=$(date -u +%Y-%m-%dT%H:%M:%SZ) -s -w" \
./cmd/gateway cmd/gateway/main.go
if [ ! -f "bin/gateway" ]; then if [ ! -f "bin/gateway" ]; then
echo "❌ Build failed" echo "❌ Build failed"

View File

@ -72,14 +72,11 @@ fi
# Build application # Build application
echo "🔨 Building application..." echo "🔨 Building application..."
# Create bin directory if it doesn't exist go build -o bin/torrentGateway \
mkdir -p bin
go build -o bin/gateway \
-ldflags "-X main.version=$(git describe --tags --always) -X main.buildTime=$(date -u +%Y-%m-%dT%H:%M:%SZ) -s -w" \ -ldflags "-X main.version=$(git describe --tags --always) -X main.buildTime=$(date -u +%Y-%m-%dT%H:%M:%SZ) -s -w" \
./cmd/gateway cmd/gateway/*.go
if [ ! -f "bin/gateway" ]; then if [ ! -f "bin/torrentGateway" ]; then
echo "❌ Build failed" echo "❌ Build failed"
exit 1 exit 1
fi fi
@ -91,14 +88,14 @@ mkdir -p "$INSTALL_DIR"/{bin,data,configs,logs,backups,web}
mkdir -p "$INSTALL_DIR/data"/{blobs,chunks,transcoded,thumbnails,metadata} mkdir -p "$INSTALL_DIR/data"/{blobs,chunks,transcoded,thumbnails,metadata}
# Copy files # Copy files
cp bin/gateway "$INSTALL_DIR/bin/" cp bin/torrentGateway "$INSTALL_DIR/bin/"
cp -r configs/* "$INSTALL_DIR/configs/" 2>/dev/null || true cp -r configs/* "$INSTALL_DIR/configs/" 2>/dev/null || true
cp -r internal/web "$INSTALL_DIR/" cp -r internal/web "$INSTALL_DIR/"
cp -r scripts "$INSTALL_DIR/" cp -r scripts "$INSTALL_DIR/"
# Set permissions # Set permissions
chown -R "$SERVICE_USER:$SERVICE_GROUP" "$INSTALL_DIR" chown -R "$SERVICE_USER:$SERVICE_GROUP" "$INSTALL_DIR"
chmod +x "$INSTALL_DIR/bin/gateway" chmod +x "$INSTALL_DIR/bin/torrentGateway"
chmod +x "$INSTALL_DIR/scripts"/*.sh chmod +x "$INSTALL_DIR/scripts"/*.sh
echo "✅ Installation directory configured" echo "✅ Installation directory configured"
@ -116,7 +113,7 @@ Type=simple
User=torrent-gateway User=torrent-gateway
Group=torrent-gateway Group=torrent-gateway
WorkingDirectory=/opt/torrent-gateway WorkingDirectory=/opt/torrent-gateway
ExecStart=/opt/torrent-gateway/bin/gateway ExecStart=/opt/torrent-gateway/bin/torrentGateway
Restart=always Restart=always
RestartSec=5 RestartSec=5
StandardOutput=journal StandardOutput=journal