1 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
2 .. SPDX-License-Identifier: CC-BY-4.0
3 .. Copyright (C) 2019 Wind River Systems, Inc.
12 1. About the INF project
13 ************************
15 This project is a reference implementation of O-Cloud infrastructure which is based on StarlingX, and it supports multi-OS.
17 * Currently the following OS are supported:
19 * Debian 11 (bullseye)
24 * Debian based is the recommended platfrom.
26 1.1 About the Debian based implementaion
27 ----------------------------------------
28 The project provde wrapper scripts to automate all the steps of `StarlingX Debian Build Guide`_ to build out the reference platform as an installable ISO image.
30 .. _`StarlingX Debian Build Guide`: https://wiki.openstack.org/wiki/StarlingX/DebianBuildEnvironment
32 1.2 About the CentOS based implementaion
33 ----------------------------------------
34 The project provde wrapper scripts to automate all the steps of `StarlingX Build Guide`_ to build out the reference platform as an installable ISO image.
36 .. _`StarlingX Build Guide`: https://docs.starlingx.io/developer_resources/build_guide.html
38 1.3 About the Yocto based implementation
39 ----------------------------------------
41 The project provde wrapper scripts to pull all required Yocto/OE layers to build out the reference platform as an installable ISO image.
43 To contribute on this project, basic knowledge of Yocto/OpenEmbedded is needed, please refer to the following docs if you want to learn about how to develop with Yocto/OpenEmbedded:
46 - `OpenEmbedded wiki`_
48 .. _`Yocto dev manual`: https://www.yoctoproject.org/docs/2.6.3/dev-manual/dev-manual.html
49 .. _`OpenEmbedded wiki`: http://www.openembedded.org/wiki/Main_Page
52 2. How to build the INF project
53 *******************************
55 2.1 How to build the Debian based image
56 ---------------------------------------
58 2.1.1 Prerequisite for Debian build environment
59 +++++++++++++++++++++++++++++++++++++++++++++++
61 NOTE: The build system for Debian requires a Linux system with Docker and python 3.x installed. The the following steps have been tested on CentOS 7 and Ubuntu 20.04.
63 * Refer to `Install docker on ubuntu`_ or `Install docker on centos`_ to install docker.
64 * Refer to `Configure_Debian_build_environment`_ to install prerequisite packges and configure for Debian build environment.
66 .. _`Install docker on ubuntu`: https://docs.docker.com/engine/install/ubuntu/
67 .. _`Install docker on centos`: https://docs.docker.com/engine/install/centos/
68 .. _`Configure_Debian_build_environment`: https://wiki.openstack.org/wiki/StarlingX/DebianBuildEnvironment#Configure_build_environment
70 2.1.2 Use wrapper script build_inf_debian.sh to build the Debian based image
71 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
75 # Get the wrapper script to build the debian image
76 $ wget -O build_inf_debian.sh 'https://gerrit.o-ran-sc.org/r/gitweb?p=pti/rtp.git;a=blob_plain;f=scripts/build_inf_debian/build_inf_debian.sh;hb=HEAD'
78 $ chmod +x build_inf_debian.sh
79 $ WORKSPACE=/path/to/workspace
80 $ ./build_inf_debian.sh -w ${WORKSPACE}
82 If all go well, you will get the ISO image in:
83 ${WORKSPACE}/prj_output/inf-image-debian-all-x86-64.iso
85 2.2 How to build the CentOS based image
86 ---------------------------------------
88 NOTE: This only supports build on CentOS 7 which will be EOL 30 Jun 2024.
90 2.2.1 Prerequisite for CentOS build environment
91 +++++++++++++++++++++++++++++++++++++++++++++++
93 NOTE: This step needs the user has sudo permission.
97 # Get the wrapper script for preparing the build environment
98 $ wget -O build_inf_prepare.sh https://gerrit.o-ran-sc.org/r/gitweb?p=pti/rtp.git;a=blob_plain;f=scripts/build_inf_centos/build_inf_prepare_jenkins.sh;hb=HEAD
100 $ chmod +x build_inf_prepare.sh
101 $ WORKSPACE=/path/to/workspace
102 $ ./build_inf_prepare.sh -w ${WORKSPACE}
104 2.2.2 Use wrapper script build_inf_centos.sh to build the CentOS based image
105 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
109 # Get the wrapper script to build the centos image
110 $ wget -O build_inf_centos.sh 'https://gerrit.o-ran-sc.org/r/gitweb?p=pti/rtp.git;a=blob_plain;f=scripts/build_inf_centos/build_inf_centos.sh;hb=HEAD'
112 $ chmod +x build_inf_centos.sh
113 $ WORKSPACE=/path/to/workspace
114 $ ./build_inf_centos.sh -w ${WORKSPACE}
116 If all go well, you will get the ISO image in:
117 ${WORKSPACE}/prj_output/inf-image-centos-all-x86-64.iso
120 2.3 How to build the Yocto based image
121 --------------------------------------
123 2.3.1 Prerequisite for Yocto build environment
124 ++++++++++++++++++++++++++++++++++++++++++++++
126 * Your host need to meet the requirements for Yocto, please refer to:
128 * `Compatible Linux Distribution`_
129 * `Supported Linux Distributions`_
130 * `Required Packages for the Build Host`_
132 The recommended and tested host is Ubuntu 16.04/18.04 and CentOS 7.
134 * To install the required packages for Ubuntu 16.04/18.04:
136 .. _`Compatible Linux Distribution`: https://www.yoctoproject.org/docs/2.7.3/brief-yoctoprojectqs/brief-yoctoprojectqs.html#brief-compatible-distro
137 .. _`Supported Linux Distributions`: https://www.yoctoproject.org/docs/2.7.3/ref-manual/ref-manual.html#detailed-supported-distros
138 .. _`Required Packages for the Build Host`: https://www.yoctoproject.org/docs/2.7.3/ref-manual/ref-manual.html#required-packages-for-the-build-host
142 $ sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib \
143 build-essential chrpath socat cpio python python3 python3-pip python3-pexpect \
144 xz-utils debianutils iputils-ping make xsltproc docbook-utils fop dblatex xmlto \
147 * To install the required packages for CentOS 7:
151 $ sudo yum install -y epel-release
153 $ sudo yum install gawk make wget tar bzip2 gzip python unzip perl patch \
154 diffutils diffstat git cpp gcc gcc-c++ glibc-devel texinfo chrpath socat \
155 perl-Data-Dumper perl-Text-ParseWords perl-Thread-Queue perl-Digest-SHA \
156 python34-pip xz which SDL-devel xterm
158 2.3.2 Use wrapper script build_inf_yocto.sh to setup build the Yocto based image
159 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
163 # Get the wrapper script with either curl or wget
164 $ curl -o build_inf_yocto.sh 'https://gerrit.o-ran-sc.org/r/gitweb?p=pti/rtp.git;a=blob_plain;f=scripts/build_inf_yocto/build_inf_yocto.sh;hb=HEAD'
165 $ wget -O build_inf_yocto.sh 'https://gerrit.o-ran-sc.org/r/gitweb?p=pti/rtp.git;a=blob_plain;f=scripts/build_inf_yocto/build_inf_yocto.sh;hb=HEAD'
167 $ chmod +x build_inf_yocto.sh
168 $ WORKSPACE=/path/to/workspace
169 $ ./build_inf_yocto.sh -w ${WORKSPACE}
171 If all go well, you will get the ISO image in:
172 ${WORKSPACE}/prj_output/inf-image-yocto-aio-x86-64.iso