try again

This commit is contained in:
maddalax 2024-09-21 13:03:27 -05:00
parent 9ef99fa6b7
commit 07d8a5db10
2 changed files with 5 additions and 4 deletions

View file

@ -1,6 +1,7 @@
package run package run
import ( import (
"fmt"
"github.com/maddalax/htmgo/cli/htmgo/tasks/astgen" "github.com/maddalax/htmgo/cli/htmgo/tasks/astgen"
"github.com/maddalax/htmgo/cli/htmgo/tasks/copyassets" "github.com/maddalax/htmgo/cli/htmgo/tasks/copyassets"
"github.com/maddalax/htmgo/cli/htmgo/tasks/css" "github.com/maddalax/htmgo/cli/htmgo/tasks/css"
@ -18,8 +19,8 @@ func Build() {
process.RunOrExit("rm -rf ./dist") process.RunOrExit("rm -rf ./dist")
process.RunOrExit("mkdir -p ./dist") process.RunOrExit("mkdir -p ./dist")
process.RunOrExit("env GOOS=linux GOARCH=amd64 go build -o ./dist/app-linux-amd64 .") process.RunOrExit("env go build -o ./dist .")
process.RunOrExit("go build -o ./dist/app .") process.RunOrExit("go build -o ./dist/app .")
process.RunOrExit("echo \"Build successful\"") fmt.Printf("Executable built at %s\n", process.GetPathRelativeToCwd("dist"))
} }

View file

@ -16,8 +16,8 @@ RUN go mod download
COPY . . COPY . .
# Build the Go binary for Linux # Build the Go binary for Linux
RUN GOPRIVATE=github.com/maddalax LOG_LEVEL=debug CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go run github.com/maddalax/htmgo/cli/htmgo@latest tailwind-cli RUN GOPRIVATE=github.com/maddalax LOG_LEVEL=debug go run github.com/maddalax/htmgo/cli/htmgo@latest tailwind-cli
RUN GOPRIVATE=github.com/maddalax LOG_LEVEL=debug CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go run github.com/maddalax/htmgo/cli/htmgo@latest build RUN GOPRIVATE=github.com/maddalax LOG_LEVEL=debug go run github.com/maddalax/htmgo/cli/htmgo@latest build
# Stage 2: Create the smallest possible image # Stage 2: Create the smallest possible image
FROM gcr.io/distroless/base-debian11 FROM gcr.io/distroless/base-debian11