Skip to content
This repository was archived by the owner on Mar 9, 2025. It is now read-only.

Commit c388d48

Browse files
committed
Merge remote-tracking branch 'origin/main' into 646-bringing-your-own-registry
2 parents 2cfb3a4 + f9aef3c commit c388d48

File tree

21 files changed

+150
-83
lines changed

21 files changed

+150
-83
lines changed

.github/workflows/build.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
- name: Set up Go
2424
uses: actions/setup-go@v4
2525
with:
26-
go-version: 1.22.0
26+
go-version: 1.22.1
2727

2828
- id: go-cache-paths
2929
run: |
@@ -68,7 +68,7 @@ jobs:
6868
- name: Set up Go
6969
uses: actions/setup-go@v4
7070
with:
71-
go-version: 1.22.0
71+
go-version: 1.22.1
7272
- name: Set Node version
7373
uses: actions/setup-node@v3
7474
with:
@@ -108,7 +108,7 @@ jobs:
108108
- name: Set up Go
109109
uses: actions/setup-go@v4
110110
with:
111-
go-version: 1.22.0
111+
go-version: 1.22.1
112112
- id: go-cache-paths
113113
run: |
114114
echo "::set-output name=go-build::$(go env GOCACHE)"
@@ -140,7 +140,7 @@ jobs:
140140
- name: Set up Go
141141
uses: actions/setup-go@v4
142142
with:
143-
go-version: 1.22.0
143+
go-version: 1.22.1
144144
- id: go-cache-paths
145145
run: |
146146
echo "::set-output name=go-build::$(go env GOCACHE)"
@@ -172,7 +172,7 @@ jobs:
172172
- name: Set up Go
173173
uses: actions/setup-go@v4
174174
with:
175-
go-version: 1.22.0
175+
go-version: 1.22.1
176176
- name: ⬇️ Check out code into the Go module directory
177177
uses: actions/checkout@v1
178178
with:
@@ -188,7 +188,7 @@ jobs:
188188
- name: Set up Go
189189
uses: actions/setup-go@v4
190190
with:
191-
go-version: 1.22.0
191+
go-version: 1.22.1
192192
- name: ⬇️ Check out code into the Go module directory
193193
uses: actions/checkout@v1
194194
with:

.github/workflows/publish-cli.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set up Go
1717
uses: actions/setup-go@v4
1818
with:
19-
go-version: 1.22.0
19+
go-version: 1.22.1
2020
- name: ⬇️ Check out code into the Go module directory
2121
uses: actions/checkout@v3
2222
with:

.github/workflows/publish-image-builder.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set up Go
1717
uses: actions/setup-go@v4
1818
with:
19-
go-version: 1.22.0
19+
go-version: 1.22.1
2020
- name: ⬇️ Check out code into the Go module directory
2121
uses: actions/checkout@v3
2222
with:

.github/workflows/publish.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set up Go
1717
uses: actions/setup-go@v4
1818
with:
19-
go-version: 1.22.0
19+
go-version: 1.22.1
2020
- name: ⬇️ Check out code into the Go module directory
2121
uses: actions/checkout@v3
2222
with:

cmd/dashboard/dashboard.go

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -100,12 +100,9 @@ func main() {
100100
)
101101
go alertStateManager.Run()
102102

103-
stopCh := make(chan struct{})
103+
stopCh := make(chan os.Signal, 1)
104104
defer close(stopCh)
105-
106-
gimletdStopCh := make(chan os.Signal, 1)
107-
signal.Notify(gimletdStopCh, syscall.SIGHUP, syscall.SIGINT, syscall.SIGTERM, syscall.SIGQUIT)
108-
waitCh := make(chan struct{})
105+
signal.Notify(stopCh, syscall.SIGHUP, syscall.SIGINT, syscall.SIGTERM, syscall.SIGQUIT)
109106

110107
if config.GitopsRepo != "" || config.GitopsRepoDeployKeyPath != "" {
111108
panic("GITOPS_REPO and GITOPS_REPO_DEPLOY_KEY_PATH are deprecated." +
@@ -148,10 +145,13 @@ func main() {
148145
go repoCache.Run()
149146
log.Info("Repo cache initialized")
150147

148+
gitopsQueue := make(chan int, 1000)
149+
151150
artifactsWorker := worker.NewArtifactsWorker(
152151
repoCache,
153152
store,
154153
triggerArtifactGeneration,
154+
gitopsQueue,
155155
)
156156
go artifactsWorker.Run()
157157

@@ -166,7 +166,7 @@ func main() {
166166
go weeklyReporter.Run()
167167
}
168168

169-
imageBuildWorker := worker.NewImageBuildWorker(store, successfullImageBuilds)
169+
imageBuildWorker := worker.NewImageBuildWorker(store, successfullImageBuilds, gitopsQueue)
170170
go imageBuildWorker.Run()
171171

172172
chartUpdatePullRequests := map[string]interface{}{}
@@ -213,9 +213,9 @@ func main() {
213213
perf,
214214
gitUser,
215215
config.GitHost,
216+
gitopsQueue,
216217
)
217218
go gitopsWorker.Run()
218-
log.Info("Gitops worker started")
219219

220220
if config.ReleaseStats == "enabled" {
221221
releaseStateWorker := &worker.ReleaseStateWorker{
@@ -268,6 +268,7 @@ func main() {
268268
logger,
269269
gitServer,
270270
gitUser,
271+
gitopsQueue,
271272
)
272273

273274
go func() {
@@ -285,7 +286,8 @@ func main() {
285286
}
286287
}
287288

288-
<-waitCh
289+
<-stopCh
290+
close(gitopsQueue)
289291
log.Info("Successfully cleaned up resources. Stopping.")
290292
}
291293

go.mod

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
module github.com/gimlet-io/gimlet-cli
22

3-
go 1.22
3+
go 1.22.1
44

55
// Replace digest lib to master to gather access to BLAKE3.
66
// xref: https://github.com/opencontainers/go-digest/pull/66
@@ -80,7 +80,7 @@ require (
8080
k8s.io/api v0.29.2
8181
k8s.io/apimachinery v0.29.2
8282
k8s.io/client-go v0.29.2
83-
modernc.org/sqlite v1.24.0
83+
modernc.org/sqlite v1.29.4
8484
sigs.k8s.io/kustomize/api v0.16.0
8585
sigs.k8s.io/yaml v1.4.0
8686
)
@@ -108,16 +108,21 @@ require (
108108
github.com/go-git/go-git-fixtures/v4 v4.3.1 // indirect
109109
github.com/go-logr/stdr v1.2.2 // indirect
110110
github.com/google/gnostic-models v0.6.8 // indirect
111+
github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 // indirect
111112
github.com/gookit/color v1.5.3 // indirect
112113
github.com/hashicorp/errwrap v1.1.0 // indirect
113114
github.com/hashicorp/go-multierror v1.1.1 // indirect
115+
github.com/hashicorp/golang-lru/v2 v2.0.7 // indirect
114116
github.com/hashicorp/hcl v1.0.0 // indirect
115117
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect
116118
github.com/lestrrat-go/httprc v1.0.5 // indirect
117119
github.com/lestrrat-go/jwx/v2 v2.0.21 // indirect
118120
github.com/lithammer/fuzzysearch v1.1.8 // indirect
119121
github.com/mattn/go-sqlite3 v2.0.3+incompatible // indirect
122+
github.com/miekg/dns v1.1.43 // indirect
120123
github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f // indirect
124+
github.com/ncruces/go-strftime v0.1.9 // indirect
125+
github.com/onsi/ginkgo/v2 v2.15.0 // indirect
121126
github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec // indirect
122127
github.com/segmentio/asm v1.2.0 // indirect
123128
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
@@ -131,15 +136,17 @@ require (
131136
golang.org/x/tools v0.18.0 // indirect
132137
google.golang.org/genproto/googleapis/rpc v0.0.0-20240228224816-df926f6c8641 // indirect
133138
gopkg.in/evanphx/json-patch.v5 v5.9.0 // indirect
139+
gotest.tools/v3 v3.5.0 // indirect
134140
lukechampine.com/uint128 v1.2.0 // indirect
135-
modernc.org/cc/v3 v3.40.0 // indirect
136-
modernc.org/ccgo/v3 v3.16.13 // indirect
137-
modernc.org/libc v1.22.5 // indirect
138-
modernc.org/mathutil v1.5.0 // indirect
139-
modernc.org/memory v1.5.0 // indirect
141+
modernc.org/cc/v3 v3.41.0 // indirect
142+
modernc.org/ccgo/v3 v3.16.15 // indirect
143+
modernc.org/gc/v3 v3.0.0-20240107210532-573471604cb6 // indirect
144+
modernc.org/libc v1.41.0 // indirect
145+
modernc.org/mathutil v1.6.0 // indirect
146+
modernc.org/memory v1.7.2 // indirect
140147
modernc.org/opt v0.1.3 // indirect
141-
modernc.org/strutil v1.1.3 // indirect
142-
modernc.org/token v1.0.1 // indirect
148+
modernc.org/strutil v1.2.0 // indirect
149+
modernc.org/token v1.1.0 // indirect
143150
)
144151

145152
require (
@@ -195,7 +202,7 @@ require (
195202
github.com/go-openapi/jsonreference v0.20.4 // indirect
196203
github.com/go-openapi/swag v0.22.9 // indirect
197204
github.com/goccy/go-json v0.10.2 // indirect
198-
github.com/gofrs/uuid v4.2.0+incompatible // indirect
205+
github.com/gofrs/uuid v4.4.0+incompatible // indirect
199206
github.com/gogo/protobuf v1.3.2 // indirect
200207
github.com/golang/protobuf v1.5.3 // indirect
201208
github.com/gomarkdown/markdown v0.0.0-20191123064959-2c17d62f5098 // indirect
@@ -278,7 +285,7 @@ require (
278285
golang.org/x/term v0.18.0 // indirect
279286
golang.org/x/text v0.14.0 // indirect
280287
golang.org/x/time v0.5.0 // indirect
281-
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
288+
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
282289
google.golang.org/appengine v1.6.8 // indirect
283290
google.golang.org/grpc v1.62.0 // indirect
284291
google.golang.org/protobuf v1.32.0 // indirect

0 commit comments

Comments
 (0)