Add Dockerfile for building cc-oci-runtime and qemu-lite for Centos and Fedora#3
Conversation
|
Missing qemu-lite spec, working on that :) |
ef16018 to
1fc6e0b
Compare
|
The qemu-lite spec is added |
This will generate the rpms for cc-oci-runtime & qemu-lite on the host for Centos and Fedora Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
| @@ -0,0 +1,6 @@ | |||
| # Ignore rpmbuild generated folders | |||
| 2.1/build/rpmbuild/BUILD | |||
There was a problem hiding this comment.
yes 2.1 will be the new path
There was a problem hiding this comment.
yes 2.1 will be the new path
| @@ -0,0 +1,7 @@ | |||
| # To build | |||
| `$ sudo docker build -t centos-clear-containers .` | |||
There was a problem hiding this comment.
why sudo is needed to build the image?
There was a problem hiding this comment.
I tried without sudo but it was not working even if I do a # docker ps
There was a problem hiding this comment.
I tried without sudo but it was not working even if I do a # docker ps
2.1/build/build-rpms.sh
Outdated
| mv ~/rpmbuild/SOURCES/2.1.0-rc.6.tar.gz ~/rpmbuild/SOURCES/cc-oci-runtime-2.1.0.rc.6.tar.gz | ||
|
|
||
| # Check os-distribution for build requirements for cc-oci-runtime | ||
| if [ `cat /etc/os-release | grep id | cut -d '=' -f2 | head -1` == "centos" ]; then |
There was a problem hiding this comment.
if [ cat /etc/os-release | grep ID | cut -d '=' -f2 | head -1 == "centos" ]; then
ID is in capitals
| @@ -0,0 +1,66 @@ | |||
| diff --git a/Makefile.am b/Makefile.am | |||
There was a problem hiding this comment.
This entire file can be only one instead of one for centos and other for fedora.
You can replace the content of this with the content of:
| --with-cc-kernel=/usr/share/clear-containers/vmlinux.container \ | ||
| --with-cc-image=/usr/share/clear-containers/clear-containers.img \ | ||
| --with-cc-image-systemdsystemunitdir=/usr/lib/systemd/system \ | ||
| --enable-autogopath |
There was a problem hiding this comment.
This only works if you apply the patch that is submitted here:
2.1/build/build-rpms.sh
Outdated
| #!/bin/bash | ||
|
|
||
| # Download cc-oci-runtime.tar.gz | ||
| curl -OkL https://github.com/01org/cc-oci-runtime/archive/2.1.0-rc.6.tar.gz |
There was a problem hiding this comment.
Better to use params instead of hardcoded $1 (the tag to use to build cc-oci-runtime)
2.1/build/build-rpms.sh
Outdated
| # Setup cc-oci-runtime | ||
| rpmdev-setuptree | ||
| cd ~/rpmbuild/SOURCES | ||
| mv ~/2.1.0-rc.6.tar.gz ~/rpmbuild/SOURCES |
There was a problem hiding this comment.
params? tags? instead hardcoded
| mv ~/2.1.0-rc.6.tar.gz ~/rpmbuild/SOURCES | ||
|
|
||
| # Move qemu-lite tar | ||
| mv ~/da5004e3ffc6a79df82d1b9d8f8533c4045f193c.tar.gz ~/rpmbuild/SOURCES |
There was a problem hiding this comment.
params? tags? instead hardcoded
2.1/build/build-rpms.sh
Outdated
| mv ~/da5004e3ffc6a79df82d1b9d8f8533c4045f193c.tar.gz ~/rpmbuild/SOURCES | ||
|
|
||
| # Update cc-oci-runtime tar name | ||
| mv ~/rpmbuild/SOURCES/2.1.0-rc.6.tar.gz ~/rpmbuild/SOURCES/cc-oci-runtime-2.1.0.rc.6.tar.gz |
There was a problem hiding this comment.
params? tags? instead hardcoded
* Adds parameter to build X version of cc-oci-runtime * Adds the gopath patch currently in revision * Adds the race condition fix patch Signed-off-by: Geronimo Orozco <geronimo.orozco@intel.com>
Modification to cc-oci-runtime automate build on CentOS
|
Modifications will be apply to support 2.1.1 |
This will build the rpms for cc-oci-runtime and qemu-lite. Signed-off-by: Gabriela Cervantes <gabriela.cervantes.tellez@intel.com>
|
lgtm |
|
LGTM |
Signed-off-by: Gabriela Cervantes gabriela.cervantes.tellez@intel.com