-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathMakefile
29 lines (21 loc) · 1.24 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
VERSION=v0.20.7
build: docker/mods/JunimoServer $(shell find docker -type f)
docker build --platform=amd64 -t gcr.io/junimo-host/stardew-base:$(VERSION) -f docker/Dockerfile .
clean:
rm -rf ./docker/mods/JunimoServer
rm -rf ./mod/build
docker/mods/JunimoServer: $(shell find mod/JunimoServer/**/*.cs -type f) ./mod/JunimoServer/JunimoServer.csproj
ifeq ($(CI), true)
cd mod && dotnet build -o ./build --configuration Release "/p:EnableModZip=false;EnableModDeploy=false;GamePath=/home/runner/actions-runner/_work/junimohost-stardew-server/junimohost-stardew-server/Stardew Valley"
else
cd mod && dotnet build -o ./build --configuration Release
endif
mkdir -p ./docker/mods/JunimoServer
ls ./mod/build
cp ./mod/build/JunimoServer.dll ./mod/build/Microsoft.Extensions.Logging.Abstractions.dll ./mod/build/Google.Protobuf.dll ./mod/build/Grpc.Core.Api.dll ./mod/build/Grpc.Net.Client.dll ./mod/build/Grpc.Net.Common.dll ./mod/JunimoServer/manifest.json ./docker/mods/JunimoServer
game-daemon: $(shell find daemon -type f)
GOOS=linux GOARCH=amd64 go build -o game-daemon ./cmd/daemon/daemon.go
push: build
docker push gcr.io/junimo-host/stardew-base:$(VERSION)
daemon_windows:
cd daemon && set GOOS=linux && go build -o game-daemon ./cmd/daemon/daemon.go