Skip to content

Commit

Permalink
Bugfixes
Browse files Browse the repository at this point in the history
  • Loading branch information
u220374 committed May 15, 2017
1 parent 9a094ca commit 2cc6d8a
Show file tree
Hide file tree
Showing 4 changed files with 119 additions and 4 deletions.
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,11 @@ oc adm pod-network join-projects --to=ose-mon-a ose-mon-c
# Do this for each project a,b,c
oc project ose-mon-a

# IMAGE_SPEC = If you want to use our image use "oscp/openshift-monitoring:version"
# HUB-Mode: IMAGE_SPEC = If you want to use our image use "oscp/openshift-monitoring:version"
oc process -f ose-mon-template.yaml -v DAEMON_PUBLIC_ROUTE=xxx,DS_HUB_ADDRESS=xxx,IMAGE_SPEC=xxx | oc create -f -

# Standalone-Mode:
oc process -f ose-mon-standalone-template.yaml -v DAEMON_PUBLIC_ROUTE=daemon-ose-mon-b.your-route.com IMAGE_SPEC=oscp/openshift-monitoring:xxxx | oc create -f -
```

### Master nodes
Expand Down
2 changes: 1 addition & 1 deletion daemon/client/checks/openshift.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ func CheckDnsNslookupOnKubernetes() (bool, string) {
if (strings.Contains(stdOut, "Server") && strings.Count(stdOut, "Address") >= 2 && strings.Contains(stdOut, "Name")) {
isOk = true
} else {
msg += "NsLookup had wrong output"
msg += "Problem with dns to kubernetes. nsLookup had wrong output"
}

return isOk, msg
Expand Down
4 changes: 2 additions & 2 deletions daemon/client/handlers/minor.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func HandleMinorChecks(daemonType string, w http.ResponseWriter, r *http.Request
Message: msg,
})

ok, msg = checks.CheckHttpService(true)
ok, msg = checks.CheckHttpService(false)
responses = append(responses, models.CheckState{
State: ok,
Message: msg,
Expand Down Expand Up @@ -62,7 +62,7 @@ func HandleMinorChecks(daemonType string, w http.ResponseWriter, r *http.Request
Message: msg,
})

ok, msg = checks.CheckHttpService(true)
ok, msg = checks.CheckHttpService(false)
responses = append(responses, models.CheckState{
State: ok,
Message: msg,
Expand Down
112 changes: 112 additions & 0 deletions install/ose-mon-standalone-template.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
apiVersion: v1
kind: Template
metadata:
creationTimestamp: null
name: daemon.standalone.yml
objects:
- apiVersion: v1
kind: Service
metadata:
annotations:
openshift.io/generated-by: OpenShiftNewApp
creationTimestamp: null
labels:
app: daemon
name: daemon
spec:
ports:
- name: 8090-tcp
port: 8090
protocol: TCP
targetPort: 8090
selector:
app: daemon
sessionAffinity: None
type: ClusterIP
status:
loadBalancer: {}
- apiVersion: v1
kind: DeploymentConfig
metadata:
annotations:
openshift.io/generated-by: OpenShiftNewApp
creationTimestamp: null
generation: 4
labels:
app: daemon
name: daemon
spec:
replicas: 1
selector:
app: daemon
deploymentconfig: daemon
strategy:
resources: {}
rollingParams:
intervalSeconds: 1
maxSurge: 25%
maxUnavailable: 25%
timeoutSeconds: 600
updatePeriodSeconds: 1
type: Rolling
template:
metadata:
annotations:
openshift.io/container.daemon.image.entrypoint: '["daemon"]'
openshift.io/generated-by: OpenShiftNewApp
creationTimestamp: null
labels:
app: daemon
deploymentconfig: daemon
spec:
containers:
- env:
- name: WITH_HUB
value: "false"
- name: DAEMON_TYPE
value: POD
- name: POD_NAMESPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
image: ${IMAGE_SPEC}
imagePullPolicy: IfNotPresent
name: daemon
resources: {}
terminationMessagePath: /dev/termination-log
dnsPolicy: ClusterFirst
restartPolicy: Always
securityContext: {}
terminationGracePeriodSeconds: 30
status:
availableReplicas: 1
observedGeneration: 4
replicas: 1
updatedReplicas: 1
- apiVersion: v1
kind: Route
metadata:
annotations:
openshift.io/host.generated: "true"
creationTimestamp: null
labels:
app: daemon
name: daemon
spec:
host: ${DAEMON_PUBLIC_ROUTE}
port:
targetPort: 8090-tcp
to:
kind: Service
name: daemon
weight: 100
parameters:
- description: The public route of the daemon
name: DAEMON_PUBLIC_ROUTE
required: true
value: daemon.namespace.defaultroute.com
- description: The pull spec of the image
name: IMAGE_SPEC
required: true
value: 172.30.151.39:5000/project/daemon

0 comments on commit 2cc6d8a

Please sign in to comment.