-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
33 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Build Docker image | ||
docker build -t vprodemo.azurecr.io/console:v${nextRelease.version} . | ||
|
||
# Build for Linux | ||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-s -w -X 'github.com/open-amt-cloud-toolkit/console/internal/app.Version=${nextRelease.version}'" -trimpath -o console_linux_x64 ./cmd/app/main.go | ||
|
||
# Build for Windows | ||
CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -ldflags "-s -w -X 'github.com/open-amt-cloud-toolkit/console/internal/app.Version=${nextRelease.version}'" -trimpath -o console_windows_x64.exe ./cmd/app/main.go | ||
|
||
# Build for Mac (x64) | ||
CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -ldflags "-s -w -X 'github.com/open-amt-cloud-toolkit/console/internal/app.Version=${nextRelease.version}'" -trimpath -o console_mac_x64 ./cmd/app/main.go | ||
|
||
# Build for Mac (arm64) | ||
CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build -ldflags "-s -w -X 'github.com/open-amt-cloud-toolkit/console/internal/app.Version=${nextRelease.version}'" -trimpath -o console_mac_arm64 ./cmd/app/main.go | ||
|
||
# Mark the Unix system outputs as executable | ||
chmod +x console_linux_x64 | ||
chmod +x console_mac_x64 | ||
chmod +x console_mac_arm64 | ||
|
||
# Add them to tar files respectively | ||
tar cvf console_linux_x64.tar console_linux_x64 | ||
tar cvf console_mac_x64.tar console_mac_x64 | ||
tar cvf console_mac_arm64.tar console_mac_arm64 |