github.com/octohelm/cuemod@v0.9.4/wagon.cue (about) 1 package main 2 3 import ( 4 "strings" 5 6 "wagon.octohelm.tech/core" 7 "github.com/innoai-tech/runtime/cuepkg/golang" 8 ) 9 10 client: core.#Client & { 11 env: { 12 GH_USERNAME: string | *"" 13 GH_PASSWORD: core.#Secret 14 } 15 } 16 17 pkg: version: core.#Version & {} 18 19 settings: core.#Setting & { 20 registry: "ghcr.io": auth: { 21 username: client.env.GH_USERNAME 22 secret: client.env.GH_PASSWORD 23 } 24 } 25 26 actions: go: golang.#Project & { 27 source: { 28 path: "." 29 include: [ 30 "cmd/", 31 "pkg/", 32 "internal/", 33 "go.mod", 34 "go.sum", 35 ] 36 } 37 38 version: "\(pkg.version.output)" 39 40 goos: ["linux", "darwin"] 41 goarch: ["amd64", "arm64"] 42 main: "./cmd/cuem" 43 ldflags: [ 44 "-s -w", 45 "-X \(go.module)/internal/version.version=\(go.version)", 46 ] 47 48 build: pre: [ 49 "go mod download", 50 ] 51 52 ship: { 53 name: "\(strings.Replace(go.module, "github.com/", "ghcr.io/", -1))/\(go.binary)" 54 from: "gcr.io/distroless/static-debian11:debug" 55 } 56 }