Skip to content

Commit 9c30f35

Browse files
committed
add more explanation text
1 parent 19eafc5 commit 9c30f35

File tree

1 file changed

+100
-14
lines changed

1 file changed

+100
-14
lines changed

docs/explanations/introduction.rst

Lines changed: 100 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,88 @@ Overview
55
--------
66

77
Kubernetes for EPICS IOCs provides the means to deploy and manage IOCs using
8-
modern industry standard approaches.
8+
modern industry standard approaches. The same approaches used by the large
9+
majority of micro-service and SOA applications.
910

1011
This page briefly describes the required concepts and technologies.
1112

1213

14+
Industry Standard Technologies
15+
------------------------------
16+
17+
Images and Containers
18+
~~~~~~~~~~~~~~~~~~~~~
19+
Containers provide the means to package up IOC software and execute it
20+
in a lightweight virtual environment. This includes saving the packages
21+
into public or private image registries such as DockerHub or Google Cloud
22+
Registry.
23+
24+
The Open Container Initiative (OCI) defines the set container services
25+
and their APIs such that container images can be interchanged between
26+
different frameworks.
27+
28+
Thus, in this project we develop, build and test our container images
29+
using docker or podman but the images can be run under Kubernetes' own
30+
container runtime.
31+
32+
This article does a good job of explaining the relationship between docker /
33+
containers and Kubernetes https://semaphoreci.com/blog/kubernetes-vs-docker
34+
35+
Perhaps the best outcome of using containers is that you can alter the
36+
environment inside the container to suit the IOC code, instead of altering the
37+
code to suit your infrastructure. At DLS, this means that we are able to use
38+
vanilla EPICS base and support modules. We no longer require our own
39+
forks of these repositories.
40+
41+
42+
Kubernetes
43+
~~~~~~~~~~
44+
https://kubernetes.io/
45+
46+
Kubernetes easily and efficiently manages containers across clusters of hosts.​
47+
48+
It builds upon 15 years of experience of running production workloads at
49+
Google, combined with best-of-breed ideas and practices from the community​,
50+
since it was open-sourced in 2014.
51+
52+
Today it is by far the dominant orchestration technology for containers.
53+
54+
In this project we use Kubernetes to provide a standard way of implementing
55+
these features:
56+
57+
- Auto start IOCs when servers come up​
58+
- Manually Start and Stop IOCs​
59+
- Monitor IOC status and versions​
60+
- Deploy versioned IOCs to the beamline​
61+
- Rollback to a previous IOC version​
62+
- Allocate the server which runs an IOC​
63+
- View the current log ​
64+
- View historical logs (via graylog)​
65+
- Connect to an IOC and interact with its shell
66+
- debug an ioc by starting a bash shell inside it's container
67+
- etc.
68+
69+
70+
Helm
71+
~~~~
72+
https://helm.sh/
73+
74+
Helm is the most popular package manager for Kubernetes applications​.
75+
76+
The packages are called Helm Charts​. They contain templated YAML files to
77+
define a set of resources to apply to a Kubernetes cluster​.
78+
79+
Helm has functions to deploy Charts to a cluster and manage multiple versions
80+
of the chart within the cluster​.
81+
82+
It also supports registries for storing version history of charts,
83+
much like docker.
84+
85+
In this project we use Helm Charts to define and deploy IOC instances. Each
86+
beamline has its own Helm Repository which stores current and historical
87+
version of its IOC instances.
88+
89+
1390
Concepts
1491
--------
1592

@@ -110,29 +187,38 @@ There are these types of CI:
110187
- builds the sphinx docs
111188
- publishes it to github.io pages
112189

113-
Industry Standard Technologies
114-
------------------------------
190+
Scope
191+
-----
192+
This project currently targets the low hanging fruit of x86_64 Linux Soft
193+
IOCs only.
115194

116-
Images and Containers
117-
~~~~~~~~~~~~~~~~~~~~~
118-
**TODO**
195+
Other linux architectures could be added to the Kubernetes cluster.
119196

120-
Kubernetes
121-
~~~~~~~~~~
122-
**TODO**
197+
In future it is entirely possible that Windows IOCs could also be supported
198+
since Kubernetes supports mixed OS clusters. This would be needed
199+
because windows containers require a windows host.
200+
201+
Hard IOCs will not be supported in their current form. Perhaps there is a
202+
future possibility of turning hard IOCs remote devices.
123203

124-
Helm
125-
~~~~
126-
**TODO**
127204

128205
Additional Tools
129206
----------------
130207

131208
k8s-epics-utils
132209
~~~~~~~~~~~~~~~
133-
**TODO**
210+
The project k9s-epics utils contains a script to add simple command
211+
line functions for deploying and monitoring IOCs.
212+
213+
It also provides a Dockerfile for building a personal developer image
214+
allowing a developer to work on support modules or IOCs anywhere.
215+
216+
See the repository documentation (TODO)
134217

135218
Ibek
136219
~~~~
137-
**TODO**
220+
IOC Builder for EPICS and Kubernetes provides a way to generate an IOC
221+
helm chart from a YAML description of the IOC.
138222

223+
TODO: this is in early development and not yet included in the epics-containers
224+
Organization.

0 commit comments

Comments
 (0)