diff options
| -rw-r--r-- | .gitignore | 2 | ||||
| -rw-r--r-- | Dockerfile.in | 13 | ||||
| -rw-r--r-- | Makefile | 8 | ||||
| -rw-r--r-- | README.md | 2 |
4 files changed, 15 insertions, 10 deletions
@@ -5,5 +5,5 @@ docs/latex/ ioriot/ioriot ioriot/tags systemtap/downloads/ -Dockerfile docker/ +Dockerfile diff --git a/Dockerfile.in b/Dockerfile.in index f3aacc0..60a49cf 100644 --- a/Dockerfile.in +++ b/Dockerfile.in @@ -1,11 +1,16 @@ FROM centos:7 -RUN yum install -y gcc systemtap yum-utils -ENV KERNEL KERNELVERSION -RUN yum install -y kernel-${KERNEL} kernel-devel-${KERNEL} -RUN debuginfo-install -y kernel-${KERNEL} +RUN sed -i 's/enabled=0/enabled=1/' /etc/yum.repos.d/CentOS-{Vault,Debuginfo}.repo +RUN yum install -y gcc systemtap yum-utils wget +ENV kernel KERNEL +RUN yum install -y kernel-${kernel} kernel-devel-${kernel} +RUN debuginfo-install -y kernel-${kernel} WORKDIR /ioriot ADD ./ /ioriot + +RUN mkdir -p /ioriot/systemtap/downloads RUN mkdir -p /opt/ioriot + VOLUME /opt +VOLUME /ioriot/systemtap/downloads @@ -1,11 +1,11 @@ KERNEL ?= $(shell uname -r) DESTDIR=/opt/ioriot all: - $(MAKE) -C ioriot $(MAKE) -C systemtap + $(MAKE) -C ioriot install: - $(MAKE) -C ioriot install $(MAKE) -C systemtap install + $(MAKE) -C ioriot install uninstall: test ! -z $(DESTDIR) && test -d $(DESTDIR) && rm -Rfv $(DESTDIR) || exit 0 deinstall: uninstall @@ -21,7 +21,7 @@ doxygen: test: $(MAKE) -C ioriot test dockerbuild: - sed s/KERNELVERSION/$(KERNEL)/ Dockerfile.in > Dockerfile + sed s/KERNEL/$(KERNEL)/ Dockerfile.in > Dockerfile docker build . -t ioriot:$(KERNEL) bash -c 'test ! -d /tmp/docker/opt/ && mkdir -p /tmp/docker/opt/; exit 0' - docker run -v /tmp/docker/opt:/opt -it ioriot:$(KERNEL) make all install + docker run -v /tmp/docker/opt:/opt -v /tmp/docker/downloads:/ioriot/systemtap/downloads -e 'KERNEL=$(KERNEL)' -it ioriot:$(KERNEL) make all install @@ -85,7 +85,7 @@ sudo make uninstall # Compiling I/O Riot using Docker
-In case there is no suitable build host for I/O Riot (e.g. compiling on a Mac) it is possible to use Docker to do the job. In order to build everything for CentOS 7 and Linux Kernel 3.10.0-957.1.3.el7.x86_64 just run:
+In case there is no suitable build host for I/O Riot (e.g. you want to compile the everything, including the SystemTap Kernel modules on a Mac) it is possible to use Docker for that. First of all you have to install Docker Engine. Depending on the system in use the steps may differ. Once Docker you can run the following commands to build everything for CentOS 7 and Linux Kernel 3.10.0-957.1.3.el7.x86_64 for example:
```sh
export KERNEL=3.10.0-957.1.3.el7.x86_64
|
