|
|
|
Docker Build Instructions
|
|
|
|
=====================
|
|
|
|
|
|
|
|
One of the easiest ways to build ShellB3 and reduce the chance of portability problems is to build on a docker container with as few dependencies installed as possible. The following sections provide various instructions creating a docker container, installing ShellB3 build dependencies, building a ShellB3 trim, and creating a ShellB3 distributable tarball. The instructions assume you already have Docker installed on a host machine and assume that portability is a priority.
|
|
|
|
|
|
|
|
Build for CentOS 6 Target
|
|
|
|
---------------------------------
|
|
|
|
|
|
|
|
1. Clone this repository to the Docker host (your local machine, a server, etc.) and the branch you wish to use:
|
|
|
|
|
|
|
|
git clone https://gitlab.ssec.wisc.edu/rayg/ShellB3.git
|
|
|
|
git checkout -t origin/my_branch
|
|
|
|
|
|
|
|
2. Create the docker image to be used for future ShellB3 builds:
|
|
|
|
|
|
|
|
cd ShellB3/docker_shellb3
|
|
|
|
docker build -t shellb3_centos6 .
|
|
|
|
|
|
|
|
3. Create a docker container and build ShellB3:
|
|
|
|
|
|
|
|
docker run --name shellb3_centos6_build -v /path/to/ShellB3:/host shellb3_centos6 mk_polar2grid bin_dist clean
|
|
|
|
|
|
|
|
Where `/path/to/ShellB3` is the absolute path to the ShellB3 repository you cloned in Step 1. In this example `mk_polar2grid` is the ShellB3 trim being built, this can be changed to whatever you'd like. The `clean` command should be included if you plan to build for multiple operating systems (other docker images) so that the previous build is removed from the working directory. The final tarball generated with be in `/path/to/ShellB3`
|
|
|
|
|
|
|
|
You can also replace `mk_polar2grid bin_dist clean` with any `shallbethree.sh` arguments. Note that each call to `docker run` will create a new docker container that will need to be deleted.
|
|
|
|
|
|
|
|
4. Delete the docker container when complete:
|
|
|
|
|
|
|
|
docker rm shellb3_centos6_build
|
|
|
|
|