Skip to content

Commit

Permalink
fixing iperfcon exporter
Browse files Browse the repository at this point in the history
  • Loading branch information
Oren Oichman committed Mar 5, 2024
1 parent d0b1e4e commit fff3ac9
Show file tree
Hide file tree
Showing 3,784 changed files with 888,129 additions and 182 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
18 changes: 11 additions & 7 deletions iperf-exporter/Containerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
FROM ubi8/go-toolset as build
FROM golang:alpine as build
MAINTAINER Oren Oichman "Back to Root!!!"

WORKDIR /opt/app-root
COPY cmd cmd
RUN go build cmd/iperf-exporter/iperf-exporter.go
COPY src src
WORKDIR /opt/app-root/src/iperf-exporter
RUN adduser -u 1001 -D -H exporter && \
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -o iperf-exporter

FROM ubi8/ubi-minimal
FROM scratch

USER 1001
WORKDIR /opt/app-root
COPY --from=build /opt/app-root/iperf-exporter /opt/app-root/iperf-exporter
COPY --from=build /opt/app-root/src/iperf-exporter/iperf-exporter /opt/app-root/iperf-exporter
COPY --from=build /etc/passwd /etc/passwd

USER 1001
EXPOSE 9100
ENTRYPOINT ["./iperf-exporter"]

ENTRYPOINT ["/opt/app-root/iperf-exporter"]
Original file line number Diff line number Diff line change
Expand Up @@ -15,21 +15,23 @@ spec:
spec:
containers:
- name: iperf-exporter
image: quay.io/ooichman/iperf-exporter
image: registry.gitlab.com/two.oes/iperfcon/iperf-exporter
env:
- name: IPREF_CLIENT_URI
value: ''
value: 'iperf-client-iperf.apps.cluster-rr7hf.dynamic.redhatworkshops.io'
- name: IPREF_SERVER
value: ''
value: 'iperf-server.iperf.svc'
- name: WARNING_LIMIT
value: 5000
value: "5000"
- name: IPERF_EXPORTER_PORT
value: 9100
value: "9100"
- name: INTERVAL_CHECK
value: "5"
- name: SERVER_PORT
value: 5001
value: "5001"
- name: CRITICAL_LIMIT
value: 3000
value: "3000"
- name: USE_DEBUG
value: False
value: "false"
- name: BITPERSEC_FORMAT
value: M
value: M
15 changes: 15 additions & 0 deletions iperf-exporter/Deployment/service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: v1
kind: Service
metadata:
labels:
app: iperf-exporter
name: iperf-exporter
spec:
ports:
- name: "9100"
port: 9100
protocol: TCP
targetPort: 9100
selector:
app: iperf-exporter
type: ClusterIP
10 changes: 7 additions & 3 deletions iperf-exporter/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,12 @@

if [[ -z $1 ]]; then
CONTAINER_TAG=iperf-exporter
buildah bud -f Containerfile -t ${CONTAINER_TAG} .
else
CONTAINER_TAG=$1
buildah bud -f Containerfile -t ${CONTAINER_TAG} .
buildah push ${CONTAINER_TAG}
fi

buildah bud -f Containerfile -t ${CONTAINER_TAG} .

if [[ ! -z $1 ]]; then
buildah push ${CONTAINER_TAG}
fi
163 changes: 0 additions & 163 deletions iperf-exporter/cmd/iperf-exporter/iperf-exporter.go

This file was deleted.

15 changes: 15 additions & 0 deletions iperf-exporter/pkg/mod/cache/download/cloud.google.com/go/@v/list
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
v0.26.0
v0.34.0
v0.38.0
v0.44.1
v0.44.2
v0.45.1
v0.46.3
v0.50.0
v0.52.0
v0.53.0
v0.54.0
v0.56.0
v0.57.0
v0.62.0
v0.65.0
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module cloud.google.com/go
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module cloud.google.com/go
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
module cloud.google.com/go

require (
github.com/golang/mock v1.2.0
github.com/golang/protobuf v1.2.0
github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c
github.com/google/go-cmp v0.2.0
github.com/google/martian v2.1.0+incompatible
github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57
github.com/googleapis/gax-go/v2 v2.0.4
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024
go.opencensus.io v0.21.0
golang.org/x/exp v0.0.0-20190121172915-509febef88a4
golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f
golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421
golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6
golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2
golang.org/x/time v0.0.0-20181108054448-85acf8d2951c
golang.org/x/tools v0.0.0-20190312170243-e65039ee4138
google.golang.org/api v0.4.0
google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7
google.golang.org/grpc v1.19.0
honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
module cloud.google.com/go

go 1.9

require (
github.com/golang/mock v1.3.1
github.com/golang/protobuf v1.3.2
github.com/google/btree v1.0.0
github.com/google/go-cmp v0.3.0
github.com/google/martian v2.1.0+incompatible
github.com/google/pprof v0.0.0-20190515194954-54271f7e092f
github.com/googleapis/gax-go/v2 v2.0.5
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024
go.opencensus.io v0.22.0
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522
golang.org/x/lint v0.0.0-20190409202823-959b441ac422
golang.org/x/net v0.0.0-20190620200207-3b0461eec859
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45
golang.org/x/sync v0.0.0-20190423024810-112230192c58
golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0 // indirect
golang.org/x/text v0.3.2
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0
google.golang.org/api v0.8.0
google.golang.org/appengine v1.6.1 // indirect
google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64
google.golang.org/grpc v1.21.1
honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a
rsc.io/binaryregexp v0.2.0
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
module cloud.google.com/go

go 1.9

require (
cloud.google.com/go/datastore v1.0.0
github.com/golang/mock v1.3.1
github.com/golang/protobuf v1.3.2
github.com/google/btree v1.0.0
github.com/google/go-cmp v0.3.0
github.com/google/martian v2.1.0+incompatible
github.com/google/pprof v0.0.0-20190515194954-54271f7e092f
github.com/googleapis/gax-go/v2 v2.0.5
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024
go.opencensus.io v0.22.0
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522
golang.org/x/lint v0.0.0-20190409202823-959b441ac422
golang.org/x/net v0.0.0-20190620200207-3b0461eec859
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45
golang.org/x/sync v0.0.0-20190423024810-112230192c58
golang.org/x/text v0.3.2
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0
google.golang.org/api v0.8.0
google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64
google.golang.org/grpc v1.21.1
honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a
rsc.io/binaryregexp v0.2.0
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
module cloud.google.com/go

go 1.9

require (
cloud.google.com/go/bigquery v1.0.1
cloud.google.com/go/datastore v1.0.0
github.com/golang/mock v1.3.1
github.com/golang/protobuf v1.3.2
github.com/google/go-cmp v0.3.0
github.com/google/martian v2.1.0+incompatible
github.com/google/pprof v0.0.0-20190515194954-54271f7e092f
github.com/googleapis/gax-go/v2 v2.0.5
github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024
go.opencensus.io v0.22.0
golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522
golang.org/x/lint v0.0.0-20190409202823-959b441ac422
golang.org/x/net v0.0.0-20190620200207-3b0461eec859
golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45
golang.org/x/text v0.3.2
golang.org/x/time v0.0.0-20190308202827-9d24e82272b4
golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0
google.golang.org/api v0.9.0
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55
google.golang.org/grpc v1.21.1
honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a
)
Loading

0 comments on commit fff3ac9

Please sign in to comment.