Difference between revisions of "Trigger"

From Fixme.ch
Jump to: navigation, search
 
(6 intermediate revisions by 2 users not shown)
Line 2: Line 2:
 
== Information ==
 
== Information ==
  
git clone ssh://gitolite@git.fixme.ch:1337/fixme-nice-api
+
https://trigger.fixme.ch
  
* Trigger for the space status, also controls the [[LED_Retrofit]]
+
Trigger (also known as '''ctrl''') is a web interface created to change the space status, and control [[LED_Retrofit]] and [[Orbital]] (in Lamp mode)
 +
 
 +
Git Repo: https://git.fixme.ch/FIXME/ctrl
 +
 
 +
* git clone git@git.fixme.ch:FIXME/ctrl.git
 
* It uses the [https://github.com/fixme-lausanne/Twitter-Hackerspace-Status twitter.pl and spaceapi.py scripts] to retrieve the status and to change it, using javascript and XMLHttpRequest
 
* It uses the [https://github.com/fixme-lausanne/Twitter-Hackerspace-Status twitter.pl and spaceapi.py scripts] to retrieve the status and to change it, using javascript and XMLHttpRequest
 
* It controls the LEDs over HTTP using
 
* It controls the LEDs over HTTP using
 
* It's deployed in [[Kubernetes]], the image is built locally.
 
* It's deployed in [[Kubernetes]], the image is built locally.
 
<pre>
 
ubuntu@k8s:~$ kubectl get all --namespace ctrl
 
NAME                          READY  STATUS    RESTARTS  AGE
 
pod/ledctrl-848f854c49-d6ljh  1/1    Running  0          12d
 
pod/trigger-579d7dd765-krfvk  1/1    Running  0          11d
 
 
NAME              TYPE        CLUSTER-IP      EXTERNAL-IP  PORT(S)    AGE
 
service/ledctrl  ClusterIP  10.109.61.229    <none>        5000/TCP  11d
 
service/trigger  ClusterIP  10.106.107.197  <none>        80/TCP    11d
 
 
NAME                      DESIRED  CURRENT  UP-TO-DATE  AVAILABLE  AGE
 
deployment.apps/ledctrl  1        1        1            1          12d
 
deployment.apps/trigger  1        1        1            1          12d
 
 
NAME                                DESIRED  CURRENT  READY  AGE
 
replicaset.apps/ledctrl-5ccdccc764  0        0        0      12d
 
replicaset.apps/ledctrl-848f854c49  1        1        1      12d
 
replicaset.apps/trigger-579d7dd765  1        1        1      12d
 
replicaset.apps/trigger-7966796948  0        0        0      12d
 
</pre>
 
  
 
== How to push changes ==
 
== How to push changes ==
Line 36: Line 19:
  
 
# Update the local repository
 
# Update the local repository
cd led-ctrl-2018/
+
cd ~/ctrl
 
git pull
 
git pull
  

Latest revision as of 19:34, 5 February 2023

Information

https://trigger.fixme.ch

Trigger (also known as ctrl) is a web interface created to change the space status, and control LED_Retrofit and Orbital (in Lamp mode)

Git Repo: https://git.fixme.ch/FIXME/ctrl

  • git clone git@git.fixme.ch:FIXME/ctrl.git
  • It uses the twitter.pl and spaceapi.py scripts to retrieve the status and to change it, using javascript and XMLHttpRequest
  • It controls the LEDs over HTTP using
  • It's deployed in Kubernetes, the image is built locally.

How to push changes

$ ssh ubuntu@k8s.fixme.ch

# Update the local repository
cd ~/ctrl
git pull

# Build the docker image
sudo docker build -t trigger .

# Killthe pod and watch it come back
kubectl delete --namespace ctrl pod/trigger-579d7dd765-krfvk
kubectl get --namespace=ctrl pods

Archives