Include new bug fix of fabric-tna

Includes the bug fix of watchlist
https://github.com/stratum/fabric-tna/pull/105

Change-Id: I4626e747ec71b82dbd01f6256860590e277e5e5a
1 file changed
tree: 446b0281899f768cbf4ac790f6842b1a673249b1
  1. .gitignore
  2. .gitreview
  3. CODE_OF_CONDUCT.md
  4. Dockerfile.tost
  5. Makefile
  6. Makefile.vars
  7. README.md
  8. VERSION
  9. app-build.sh
  10. app-install.sh
  11. dependencies.xml
  12. mvn_settings.sh
README.md

TOST ONOS Development Build Environment

Docker build environment capable of producing a version of ONOS and needed apps that can run with TOST. Typically the ONOS restful api would be used to include apps after ONOS is started.

Build

We provide multiple build targets for the Makefile

onos-build is used to build a specialized Docker image of ONOS (tost-onos) that will contain only the apps needed by TOST. It depends on onos target, which is used to setup the onos workspace for the build. It clones onos if it does not exist in the workspace, it will try to checkout the ONOS_VERSION first and in case of failure will try to download the patchset from remote repository. ONOS_VERSION is defined in Makefile.vars, overriding the variable at run time it is possible to build a different version of ONOS.

# Build a tost-onos image from the current workspace.
make onos-build
# Build a tost-onos image from the tip of the onos-2.2 branch.
make ONOS_VERSION=onos-2.2 onos-build
# Build a tost-onos image from the review 12345.
make ONOS_VERSION=ref/changes/72/12345/1 onos-build

Makefile will build also the apps. These are the apps currently integrated in the script: trellis-control, trellis-t3, fabric-tofino, up4, kafka-onos and fabric-tna. For each one, there is a build target.

appname-build builds with the version specified in the Makefile.vars, using the following sources in order: (1) Maven central (for released versions or snapshots); (2) Local source code (for local branch not yet pushed); (3) Gerrit/Github (for pending review in the form of refs/changes/... or pending pull request). As a prerequisite, the script prepares mvn_settings.xml file, creates the local-apps folder and checks out the code if it is not present (relies on appname target). APPNAME_VERSION, defined in Makefile.vars, can be overridden at runtime.

# Build trellis-control from the source code.
make trellis-control-build
# Build up4 app from the source code.
make up4-build
# Build fabric-tofino app from the tag 1.1.0.
make FABRIC_TOFINO_VERSION=1.1.0 fabric-tofino-build

apps-build is an additional target that automates the build process of the apps building one by one all the apps.

# Build one by one all the apps.
make apps-build

Finally, the last build target is tost-build. It builds a tost monolithic image using as base the tost-onos image. It basically adds the external apps used by TOST. It does not activate all the required apps. This step is performed during the deployment and the required apps are specified in the chart.

# Build a tost image from the current workspace.
make tost-build

Update

Use update targets to downloads commits, files, and refs from remotes.

# Update up4 app.
make up4-update
# Update one by one all the apps.
make apps-update

Clean

Use clean target to remove the local artificats generated by the tool.

# Cleans the workspace.
make clean

Push

We provide multiple push target for the Makefile. Typically, you need to first login by docker login command to push the image on a repository.

onos-push will push the tost-onos image.

make onos-push

tost-push will push the tost image on the defined DOCKER_REGISTRY and DOCKER_REPOSITORY.

make DOCKER_REPOSITORY=onosproject/ tost-push

CI/CD targets

There are two special targets used by the CI/CD jobs: docker-build and docker-push. The first target automates the build process of the tost image (check-scripts, onos-build, apps-build and tost-build). While the second one, it is just a tost-push called in a different way (temporary). Feel free to use them if you are ok with the prerequisites steps.