Skip to content

Commit 7a7c3f6

Browse files
committed
pushgateway-cleaner
1 parent d675c16 commit 7a7c3f6

11 files changed

Lines changed: 550 additions & 1 deletion

File tree

charts/overprovisioning/tests/golden/goldenfiles.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import (
1010
"github.com/stretchr/testify/suite"
1111
)
1212

13-
var update = flag.Bool("update-golden", true, "update golden test output files")
13+
var update = flag.Bool("update-golden", false, "update golden test output files")
1414

1515
type TemplateGoldenTest struct {
1616
suite.Suite
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Patterns to ignore when building packages.
2+
# This supports shell glob matching, relative path matching, and
3+
# negation (prefixed with !). Only one pattern per line.
4+
.DS_Store
5+
# Common VCS dirs
6+
.git/
7+
.gitignore
8+
.bzr/
9+
.bzrignore
10+
.hg/
11+
.hgignore
12+
.svn/
13+
# Common backup files
14+
*.swp
15+
*.bak
16+
*.tmp
17+
*~
18+
# Various IDEs
19+
.project
20+
.idea/
21+
*.tmproj
22+
.vscode/
23+
# additional files
24+
tests/
25+
*.ignore.yaml
26+
README.md
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
apiVersion: v1
2+
name: pushgateway-cleaner
3+
version: 0.0.1
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
apiVersion: batch/v1
2+
kind: CronJob
3+
metadata:
4+
name: cron-pushgateway-clean
5+
labels:
6+
app: pushgateway-clean
7+
type: cron
8+
spec:
9+
schedule: {{ .Values.cronSchedule | quote }}
10+
successfulJobsHistoryLimit: 1
11+
failedJobsHistoryLimit: 1
12+
concurrencyPolicy: Forbid
13+
jobTemplate:
14+
metadata:
15+
labels:
16+
app: pushgateway-clean
17+
type: cron
18+
spec:
19+
backoffLimit: 10
20+
template:
21+
metadata:
22+
labels:
23+
app: pushgateway-clean
24+
type: cron
25+
spec:
26+
restartPolicy: OnFailure
27+
containers:
28+
- name: cleaner
29+
image: "{{ .Values.image.repository }}:{{ .Values.image.tag }}"
30+
imagePullPolicy: {{ .Values.image.pullPolicy }}
31+
args:
32+
- "--metric-url={{ .Values.metricUrl }}"
Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
module tests
2+
3+
go 1.21
4+
5+
require (
6+
github.com/gruntwork-io/terratest v0.46.7
7+
github.com/stretchr/testify v1.8.4
8+
)
9+
10+
require (
11+
github.com/aws/aws-sdk-go v1.44.122 // indirect
12+
github.com/boombuler/barcode v1.0.1-0.20190219062509-6c824513bacc // indirect
13+
github.com/cpuguy83/go-md2man/v2 v2.0.0 // indirect
14+
github.com/davecgh/go-spew v1.1.1 // indirect
15+
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
16+
github.com/ghodss/yaml v1.0.0 // indirect
17+
github.com/go-errors/errors v1.0.2-0.20180813162953-d98b870cc4e0 // indirect
18+
github.com/go-logr/logr v1.2.3 // indirect
19+
github.com/go-openapi/jsonpointer v0.19.6 // indirect
20+
github.com/go-openapi/jsonreference v0.20.1 // indirect
21+
github.com/go-openapi/swag v0.22.3 // indirect
22+
github.com/go-sql-driver/mysql v1.4.1 // indirect
23+
github.com/gogo/protobuf v1.3.2 // indirect
24+
github.com/golang/protobuf v1.5.3 // indirect
25+
github.com/google/gnostic v0.5.7-v3refs // indirect
26+
github.com/google/go-cmp v0.5.9 // indirect
27+
github.com/google/gofuzz v1.1.0 // indirect
28+
github.com/google/uuid v1.3.0 // indirect
29+
github.com/gruntwork-io/go-commons v0.8.0 // indirect
30+
github.com/hashicorp/errwrap v1.0.0 // indirect
31+
github.com/hashicorp/go-multierror v1.1.0 // indirect
32+
github.com/imdario/mergo v0.3.11 // indirect
33+
github.com/jmespath/go-jmespath v0.4.0 // indirect
34+
github.com/josharian/intern v1.0.0 // indirect
35+
github.com/json-iterator/go v1.1.12 // indirect
36+
github.com/mailru/easyjson v0.7.7 // indirect
37+
github.com/mattn/go-zglob v0.0.2-0.20190814121620-e3c945676326 // indirect
38+
github.com/mitchellh/go-homedir v1.1.0 // indirect
39+
github.com/moby/spdystream v0.2.0 // indirect
40+
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
41+
github.com/modern-go/reflect2 v1.0.2 // indirect
42+
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
43+
github.com/pmezard/go-difflib v1.0.0 // indirect
44+
github.com/pquerna/otp v1.2.0 // indirect
45+
github.com/russross/blackfriday/v2 v2.1.0 // indirect
46+
github.com/spf13/pflag v1.0.5 // indirect
47+
github.com/urfave/cli v1.22.2 // indirect
48+
golang.org/x/crypto v0.14.0 // indirect
49+
golang.org/x/net v0.17.0 // indirect
50+
golang.org/x/oauth2 v0.7.0 // indirect
51+
golang.org/x/sys v0.13.0 // indirect
52+
golang.org/x/term v0.13.0 // indirect
53+
golang.org/x/text v0.13.0 // indirect
54+
golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 // indirect
55+
google.golang.org/appengine v1.6.7 // indirect
56+
google.golang.org/protobuf v1.31.0 // indirect
57+
gopkg.in/inf.v0 v0.9.1 // indirect
58+
gopkg.in/yaml.v2 v2.4.0 // indirect
59+
gopkg.in/yaml.v3 v3.0.1 // indirect
60+
k8s.io/api v0.27.2 // indirect
61+
k8s.io/apimachinery v0.27.2 // indirect
62+
k8s.io/client-go v0.27.2 // indirect
63+
k8s.io/klog/v2 v2.90.1 // indirect
64+
k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect
65+
k8s.io/utils v0.0.0-20230209194617-a36077c30491 // indirect
66+
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
67+
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
68+
sigs.k8s.io/yaml v1.3.0 // indirect
69+
)

0 commit comments

Comments
 (0)