Browse Source

First commit for loops DPS

Signed-off-by: Nicholas Tan Jerome <nicholas.jerome@kit.edu>
Nicholas Tan Jerome 5 years ago
commit
bf4f7aeaeb
8 changed files with 554 additions and 0 deletions
  1. 3 0
      .gitmodules
  2. 6 0
      app.py
  3. BIN
      background.png
  4. 1 0
      bora
  5. 9 0
      requirements.txt
  6. 505 0
      style.yaml
  7. 3 0
      trigger.sh
  8. 27 0
      varname.yaml

+ 3 - 0
.gitmodules

@@ -0,0 +1,3 @@
+[submodule "bora"]
+	path = bora
+	url = https://github.com/kit-ipe/bora.git

+ 6 - 0
app.py

@@ -0,0 +1,6 @@
+import subprocess
+import os
+from shutil import copyfile
+
+copyfile("./background.png", "./bora/static/background.png")
+subprocess.call(["python", "./bora/core.py"])

BIN
background.png


+ 1 - 0
bora

@@ -0,0 +1 @@
+Subproject commit 6f42327669e1ea1401a06cdd4961c0d3456a3782

+ 9 - 0
requirements.txt

@@ -0,0 +1,9 @@
+PyYAML==3.12
+backports-abc==0.4
+backports.ssl-match-hostname==3.5.0.1
+certifi==2016.8.31
+requests==2.11.1
+singledispatch==3.4.0.3
+six==1.10.0
+tornado==4.4.1
+wsgiref==0.1.2

+ 505 - 0
style.yaml

@@ -0,0 +1,505 @@
+310EEL-3-1000:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'false'
+  formula: ''
+  header:
+    size: 12
+    title: 'EEL-3-1000             '
+    weight: '400'
+  height: 44
+  larger: ''
+  left: 222px
+  lesser: ''
+  linkhtml: 'true'
+  ref: 310EEL-3-1000
+  top: 440px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '             V'
+    weight: '400'
+  width: 71
+310EEL-3-2000:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'false'
+  formula: ''
+  header:
+    size: 12
+    title: 'EEL-3-2000            '
+    weight: '400'
+  height: 44
+  larger: ''
+  left: 557px
+  lesser: ''
+  linkhtml: 'true'
+  ref: 310EEL-3-2000
+  top: 391px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '            V'
+    weight: '400'
+  width: 75
+310EEL-3-3000:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'false'
+  formula: ''
+  header:
+    size: 12
+    title: 'EEL-3-3000           '
+    weight: '400'
+  height: 44
+  larger: ''
+  left: 930px
+  lesser: ''
+  linkhtml: 'true'
+  ref: 310EEL-3-3000
+  top: 340px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '           V'
+    weight: '400'
+  width: 67
+310EEL-3-4000:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'false'
+  formula: ''
+  header:
+    size: 12
+    title: 'EEL-3-4000          '
+    weight: '400'
+  height: 44
+  larger: ''
+  left: 1315px
+  lesser: ''
+  linkhtml: 'true'
+  ref: 310EEL-3-4000
+  top: 392px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '          V'
+    weight: '400'
+  width: 66
+310EEL-3-5000:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'false'
+  formula: ''
+  header:
+    size: 12
+    title: 'EEL-3-5000         '
+    weight: '400'
+  height: 44
+  larger: ''
+  left: 1563px
+  lesser: ''
+  linkhtml: 'true'
+  ref: 310EEL-3-5000
+  top: 445px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '         V'
+    weight: '400'
+  width: 63
+310EEL-3-5010:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'false'
+  formula: ''
+  header:
+    size: 12
+    title: 'EEL-3-5010        '
+    weight: '400'
+  height: 44
+  larger: ''
+  left: 1698px
+  lesser: ''
+  linkhtml: 'true'
+  ref: 310EEL-3-5010
+  top: 445px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '        V'
+    weight: '400'
+  width: 67
+610-VAO-3-0001:
+  background_color: rgba(0, 0, 0, 0)
+  height: 123
+  icon: valve
+  left: -13px
+  linkhtml: 'false'
+  'off': '200'
+  off_condition: offgreater
+  'on': '200'
+  on_condition: onsmaller
+  ref: 610-VAO-3-0001
+  rotate: none
+  top: 488px
+  trend: 'false'
+  type: icon
+  width: 117
+620-PTM-8-4110:
+  background_color: rgba(0, 0, 0, 0)
+  height: 68
+  icon: TMP
+  left: 413px
+  linkhtml: 'false'
+  'off': '470'
+  off_condition: offsmaller
+  'on': '470'
+  on_condition: ongreater
+  ref: 620-PTM-8-4110
+  rotate: none
+  top: 794px
+  trend: 'false'
+  type: icon
+  width: 71
+620-PTM-8-4210:
+  background_color: rgba(0, 0, 0, 0)
+  height: 64
+  icon: TMP
+  left: 740px
+  linkhtml: 'false'
+  'off': '470'
+  off_condition: offsmaller
+  'on': '470'
+  on_condition: ongreater
+  ref: 620-PTM-8-4210
+  rotate: none
+  top: 691px
+  trend: 'false'
+  type: icon
+  width: 65
+620-PTM-8-4310:
+  background_color: rgba(0, 0, 0, 0)
+  height: 66
+  icon: TMP
+  left: 1120px
+  linkhtml: 'false'
+  'off': '470'
+  off_condition: offsmaller
+  'on': '470'
+  on_condition: ongreater
+  ref: 620-PTM-8-4310
+  rotate: none
+  top: 696px
+  trend: 'false'
+  type: icon
+  width: 66
+620-PTM-8-4410:
+  background_color: rgba(0, 0, 0, 0)
+  height: 63
+  icon: TMP
+  left: 1447px
+  linkhtml: 'false'
+  'off': '470'
+  off_condition: offsmaller
+  'on': '470'
+  on_condition: ongreater
+  ref: 620-PTM-8-4410
+  rotate: none
+  top: 796px
+  trend: 'false'
+  type: icon
+  width: 63
+620-RPM-8-4115:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'true'
+  formula: ''
+  header:
+    size: 12
+    title: 'RPM-8-4115                   '
+    weight: '400'
+  height: 44
+  larger: 1e-1
+  left: 490px
+  lesser: -7e-5
+  linkhtml: 'true'
+  ref: 620-RPM-8-4115
+  top: 679px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '                   mbar'
+    weight: '400'
+  width: 87
+620-RPM-8-4215:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'true'
+  formula: ''
+  header:
+    size: 12
+    title: 'RPM-8-4215                  '
+    weight: '400'
+  height: 44
+  larger: 1e-1
+  left: 813px
+  lesser: -7e-5
+  linkhtml: 'true'
+  ref: 620-RPM-8-4215
+  top: 580px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '                  mbar'
+    weight: '400'
+  width: 87
+620-RPP-8-4112:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'true'
+  formula: ''
+  header:
+    size: 12
+    title: 'RPP-8-4112                         '
+    weight: '400'
+  height: 44
+  larger: 1e-4
+  left: 328px
+  lesser: 1e-11
+  linkhtml: 'true'
+  ref: 620-RPP-8-4112
+  top: 679px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '                         mbar'
+    weight: '400'
+  width: 83
+620-RPP-8-4212:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'true'
+  formula: ''
+  header:
+    size: 12
+    title: 'RPP-8-4212                        '
+    weight: '400'
+  height: 44
+  larger: 1e-4
+  left: 645px
+  lesser: 1e-11
+  linkhtml: 'true'
+  ref: 620-RPP-8-4212
+  top: 580px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '                        mbar'
+    weight: '400'
+  width: 90
+620-RPP-8-4315:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'true'
+  formula: ''
+  header:
+    size: 12
+    title: 'RPP-8-4315                       '
+    weight: '400'
+  height: 44
+  larger: 1e-4
+  left: 1193px
+  lesser: 1e-11
+  linkhtml: 'true'
+  ref: 620-RPP-8-4315
+  top: 582px
+  trend: 'false'
+  type: data
+  unit:
+    size: 12
+    title: '                       mbar'
+    weight: '400'
+  width: 80
+620-RPP-8-4415:
+  background_color: rgba(0, 0, 0, 0)
+  decimal: '2'
+  exponential: 'true'
+  formula: ''
+  header:
+    size: '12'
+    title: RPP-8-4415
+    weight: '400'
+  height: 46
+  larger: 1e-4
+  left: 1515px
+  lesser: 1e-11
+  linkhtml: 'true'
+  ref: 620-RPP-8-4415
+  top: 681px
+  trend: 'false'
+  type: data
+  unit:
+    size: '12'
+    title: mbar
+    weight: '400'
+  width: 78
+620-VAO-3-0002:
+  background_color: rgba(0, 0, 0, 0)
+  height: 110
+  icon: valve
+  left: 1824px
+  linkhtml: 'false'
+  'off': '200'
+  off_condition: offgreater
+  'on': '200'
+  on_condition: onsmaller
+  ref: 620-VAO-3-0002
+  rotate: none
+  top: 501px
+  trend: 'false'
+  type: icon
+  width: 114
+620-VAO-8-4111:
+  background_color: rgba(0, 0, 0, 0)
+  height: 62
+  icon: valve
+  left: 416px
+  linkhtml: 'false'
+  'off': '200'
+  off_condition: offgreater
+  'on': '200'
+  on_condition: onsmaller
+  ref: 620-VAO-8-4111
+  rotate: matrix(6.12323e-17, 1, -1, 6.12323e-17, 0, 0)
+  top: 730px
+  trend: 'false'
+  type: icon
+  width: 66
+620-VAO-8-4211:
+  background_color: rgba(0, 0, 0, 0)
+  height: 63
+  icon: valve
+  left: 741px
+  linkhtml: 'false'
+  'off': '200'
+  off_condition: offgreater
+  'on': '200'
+  on_condition: onsmaller
+  ref: 620-VAO-8-4211
+  rotate: matrix(6.12323e-17, 1, -1, 6.12323e-17, 0, 0)
+  top: 630px
+  trend: 'false'
+  type: icon
+  width: 64
+620-VAO-8-4311:
+  background_color: rgba(0, 0, 0, 0)
+  height: 68
+  icon: valve
+  left: 1121px
+  linkhtml: 'false'
+  'off': '200'
+  off_condition: offgreater
+  'on': '200'
+  on_condition: onsmaller
+  ref: 620-VAO-8-4311
+  rotate: matrix(6.12323e-17, 1, -1, 6.12323e-17, 0, 0)
+  top: 631px
+  trend: 'false'
+  type: icon
+  width: 65
+620-VAO-8-4411:
+  background_color: rgba(0, 0, 0, 0)
+  height: 61
+  icon: valve
+  left: 1446px
+  linkhtml: 'false'
+  'off': '200'
+  off_condition: offgreater
+  'on': '200'
+  on_condition: onsmaller
+  ref: 620-VAO-8-4411
+  rotate: matrix(6.12323e-17, 1, -1, 6.12323e-17, 0, 0)
+  top: 736px
+  trend: 'false'
+  type: icon
+  width: 64
+header_cps:
+  background_color: rgb(255, 255, 255)
+  header:
+    size: 30
+    title: 'CPS                    '
+    weight: '400'
+  height: 41
+  left: 1789px
+  titlelink: http://ipepc57.ipe.kit.edu:4547/loops_cps/status
+  top: 62px
+  type: header
+  width: 73
+header_dps-cryo:
+  background_color: rgba(0, 0, 0, 0)
+  header:
+    size: 28
+    title: 'DPS Cryo    '
+    weight: '400'
+  height: 43
+  left: 4px
+  titlelink: http://katrin.kit.edu/status/dps/
+  top: 859px
+  type: header
+  width: 128
+header_loops-dps:
+  background_color: rgba(0, 0, 0, 0)
+  header:
+    size: 40
+    title: 'Loops @ DPS       '
+    weight: '400'
+  height: 55
+  left: 830px
+  top: 7px
+  type: header
+  width: 288
+header_v1:
+  background_color: rgba(0, 0, 0, 0)
+  header:
+    size: 60
+    title: 'V1   '
+    weight: '400'
+  height: 82
+  left: 12px
+  top: 423px
+  type: header
+  width: 64
+header_v2:
+  background_color: rgba(0, 0, 0, 0)
+  header:
+    size: 60
+    title: 'V2  '
+    weight: '400'
+  height: 82
+  left: 1846px
+  top: 437px
+  type: header
+  width: 73
+header_wgts:
+  background_color: rgb(255, 255, 255)
+  header:
+    size: 30
+    title: 'WGTS                     '
+    weight: '400'
+  height: 43
+  left: 35px
+  titlelink: http://ipepc57.ipe.kit.edu:4545/loops_wgts/status
+  top: 65px
+  type: header
+  width: 95

+ 3 - 0
trigger.sh

@@ -0,0 +1,3 @@
+# This is a manual trigger to the CPS pod at the OpenShift platform.
+# Only run this when the webhook is not working.
+curl -X POST -k https://kaas.kit.edu:8443/oapi/v1/namespaces/bora/buildconfigs/cps/webhooks/<SECRET>/generic

+ 27 - 0
varname.yaml

@@ -0,0 +1,27 @@
+310EEL-3-1000: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=3
+310EEL-3-1010: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=15
+310EEL-3-2000: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=27
+310EEL-3-2010: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=39
+310EEL-3-3000: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=51
+310EEL-3-3010: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=63
+310EEL-3-4000: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=75
+310EEL-3-4010: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=87
+310EEL-3-5000: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=99
+310EEL-3-5010: db_server=cscryo&db_name=ControlSystem_DPS&db_group=310_ION_IonenHV&db_mask=111
+320-RTP-3-1101: db_server=cscps&db_name=ControlSystem_CPS&db_group=320_STR_Strahlrohr&db_mask=180
+610-VAO-3-0001: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=0
+620-PTM-8-4110: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=3
+620-PTM-8-4210: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=12
+620-PTM-8-4310: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=15
+620-PTM-8-4410: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=18
+620-RPM-8-4115: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=45
+620-RPM-8-4215: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=57
+620-RPP-8-4112: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=69
+620-RPP-8-4212: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=72
+620-RPP-8-4315: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=75
+620-RPP-8-4415: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=78
+620-VAO-3-0002: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=99
+620-VAO-8-4111: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=102
+620-VAO-8-4211: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=117
+620-VAO-8-4311: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=123
+620-VAO-8-4411: db_server=cstloops&db_name=ControlSystem_Loop_DPS&db_group=620OuterLoop_DPS&db_mask=129