Skip to content

Latest commit

 

History

History
85 lines (53 loc) · 2.27 KB

File metadata and controls

85 lines (53 loc) · 2.27 KB

Discovering the Higgs Boson with Cloud Computing.

This repository outlines two approaches for a parallelised workflow of the ATLAS Open data higgs boson discovery analysis.

This branch contains the instructions on how to set up a Kubernetes approach whilst branch `docker-compose' contains a Docker Compose + Swarm approach.

To begin either, Docker must be installed on the machine. For the Kubernetes approach, Kubernetes must also be enabled via Docker Desktop.

Build Docker Images

First, build the Docker images for the worker and main services:

docker build -t felixgroup/worker:latest ./worker
docker build -t felixgroup/main:latest ./main

Deploy to Kubernetes

Apply all deployment manifests in the ./deployments/ directory:

kubectl apply -f ./deployments/

Expose the webserver deployment via a NodePort service:

kubectl expose deployment/webserver --port 80 --type NodePort

Check the assigned service ports:

kubectl get svc

Change the Worker Count

Alter the replicas flag to specify the worker count.

kubectl scale deployment worker --replicas=3

Access the Webserver

Open the plotting endpoint in your browser using the NodePort assigned to the webserver:

http://localhost:<insert-port-from-svc-check>/plot.png

Replace <insert-port-from-svc-check> with the actual NodePort value shown in the kubectl get svc output.

PLEASE NOTE: A plot will only appear once results begin being sent back so check the main pod log (outlined at the bottom) before refreshing.

Example output

NAME         TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)              AGE
kubernetes   ClusterIP   10.96.0.1        <none>        443/TCP              3m12s
rabbitmq     ClusterIP   10.102.191.87    <none>        5672/TCP,15672/TCP   3m2s
webserver    NodePort    10.106.242.158   <none>        80:30641/TCP         5s

In this case, 30641 is the port to be added to the URL.


Monitor the Main Node

To stream logs from the main analysis node:

kubectl logs -f deployment/main