For saving valuable resources (time, electricity, computing power, and so on), these collections will be used to generate Linux Images with the EPICS environment with full libraries for the gitlab runner. The generated image size is big, because they should contain almost all libraries for the EPICS and other applications.
The following example commands are good for building its docker image locally. And all docker images are built through the Github Actions. The Docker images are hosted at https://hub.docker.com/orgs/jeonghanlee
- Relaese the new version. Check the latest one at https://hub.docker.com/repository/docker/jeonghanlee/rocky8-epics
./release.bash v1.x.x
- Everything works within github action, release latest one
./release.bash
bash docker_builder.bash -t debian11
bash docker_builder.bash -t rocky9
bash docker_builder.bash -t rocky8
bash docker_builder.bash -t alma8
bash docker_builder.bash -t centos7
These images are optimized for the Gitlab Runner. The following example .gitlab-ci.yml
shows how to integrate them
build-centos7:
stage: build
tags:
- centos7-epics
script:
- source /usr/local/setEnv
- shellcheck -V
- git ls-files --exclude='*.bash' --ignored | xargs shellcheck || echo "No script found!"
- caget -h
test-centos7:
stage: test
needs: [ "build-centos7" ]
tags:
- centos7-epics
script:
- source /usr/local/setEnv
- bash ${CI_PROJECT_DIR}/test.bash
build-debian10:
stage: build
tags:
- debian10-epics
script:
- source /usr/local/setEnv
- shellcheck -V
- git ls-files --exclude='*.bash' --ignored | xargs shellcheck || echo "No script found!"
- caget -h
test-debian10:
stage: test
needs: [ "build-debian10" ]
tags:
- debian10-epics
script:
- source /usr/local/setEnv
- bash ${CI_PROJECT_DIR}/test.bash
build-rocky8:
stage: build
tags:
- rocky8-epics
script:
- source /usr/local/setEnv
- caget -h
test-rocky8:
stage: test
needs: [ "build-rocky8" ]
tags:
- rocky8-epics
script:
- source /usr/local/setEnv
- bash ${CI_PROJECT_DIR}/test.bash
One needs to add /bin/bash
as ENTRYPOINT
.
$ docker run -it jeonghanlee/centos7-epics /bin/bash
root@d15155bd0e42 local]# source /usr/local/setEnv
Set the EPICS Environment as follows:
THIS Source NAME : setEpicsEnv.bash
THIS Source PATH : /usr/local/epics/R7.0.5
EPICS_BASE : /usr/local/epics/R7.0.5/base
EPICS_HOST_ARCH : linux-x86_64
EPICS_MODULES : /usr/local/epics/R7.0.5/modules
PATH : /usr/local/epics/R7.0.5/base/bin/linux-x86_64:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
LD_LIBRARY_PATH : /usr/local/epics/R7.0.5/base/lib/linux-x86_64
Enjoy Everlasting EPICS!
The EPICS environment and others path can be defined via a shell script located in ${INSTALL_LOCATION}
. Its default location is /usr/local
source /usr/local/setEnv
The additional application(s) (for example, pmd
) is installed in /usr/local/apps
path.
export DOCKER_DEFAULT_PLATFORM=linux/amd64