Clone the CORD repository
From the home directory, use repo to clone the repository
Master is only used as example. You can substitute it with your favorite branch, for example cord-2.0 or cord-3.0. You can also use “flavour” specific manifests such as “mcord” or “ecord”. The “flavour” you use here is not correlated to the profile you will choose to run later but it’s suggested that you use the corresponding manifest for the deployment you want. AN example is using the “ecord” profile and then deploy the ecord.yml service_profile.
When this is complete, a listing (ls) inside this directory should yield output similar to:
Build the cord dev VM
Install manually all the software needed, directly on the dev machine, might be a long and non trivial task. This is why the environment leverages Vagrant to spawn a VM with the tools required to build and deploy CORD.
To create the development machine the following Vagrant command can be used.
This will create an Ubuntu 14.04 LTS virtual machine and will install some required packages, such as Docker, Docker Compose, and Oracle Java 8.
Make sure the VM can obtain sufficient resources. It may takes several minutes for the first command vagrant up corddev to complete, as it will include creating the VM, as well as downloading and installing various software packages.
Once the Vagrant VM is created and provisioned, you will see output ending with:
From the moment the VM gets created, it shares a folder with the OS below (the one of the server or of your personal computer). This means that what was the installation root directory (~/cord), will be also available in the VM under /cord.
Log into the CORD dev VM
From the build directory, run the following command to connect to the development VM created
Once inside the VM, you can find the deployment artifacts in the /cord directory.
In the VM, let’s move to the /cord/build directory before continuing.
Fetch the Docker images
The fetching phase of the deployment pulls Docker images from the public repository down to the VM, and clones the git submodules that are part of the project. This phase can be initiated with the following command:
The first time you run ./gradlew it will download the gradle binary from the Internet and installs it locally. This is a one time operation, but may be time consuming, depending on the speed of your Internet connection.
it’s unfortunately still quite common to see this command fail due to network timeouts. If happens, please be patient and run again the command.
Once the fetch command has successfully run, the step is complete. After the command completes you should be able to see the Docker images that were downloaded using the docker images command on the development machine:
Build the Docker images
Bare metal provisioning leverages utilities built and packaged as Docker container images. The images can be built by using the following command.
Once the buildImages command successfully runs the task is complete. The CORD artifacts have been built and the Docker images can be viewed by using the docker images command on the dev VM:
Not all the docker machines listed are created by the CORD project but are instead used as a base to create other images.