Skip to content

CenturyLink-ViNO/vino-product

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ViNO

Requirements

Before you download and build the ViNO project, make sure that your system meets the following requirements:

Hardware requirements

Your development workstation should meet or exceed these hardware requirements:

  • At least 2 CPUs
  • At least 20 GB of free disk space to checkout and build the source code
  • You need at least 4 GB of RAM.
  • Internet connection

Software requirements

The ViNO project is traditionally developed and tested on CentOS release 7.7 Minimal (CentOS-7-x86_64-Minimal-1908.iso), but other distributions may be used.

Your workstation must have the software listed below. See Establishing a Build Environment for additional required packages and the commands to install them.

  • Java 8
  • Ant
  • Git
  • Docker
  • Ruby
  • NodeJS
  • ESLint
  • Lessc
  • Typescript

Establishing a Build Environment (CentOS/RHEL)

This section describes how to set up your local work environment to build the ViNO project.

Installing the JDK (Java 8)

sudo yum install java-1.8.0-openjdk-devel

Installing Ant

sudo yum install ant ant-contrib

Installing EPEL repository

sudo yum install epel-release

Installing required packages

sudo yum install git docker jq nodejs

Setting up the environment

sudo npm i -g less
sudo npm i -g [email protected]
sudo npm i -g [email protected]
sudo npm i -g @typescript-eslint/[email protected]
sudo npm i -g @typescript-eslint/[email protected]

Setting up Docker

// Create the docker group and add your user
sudo groupadd docker
sudo usermod -aG docker <user>

// Log out and log back in so that your group membership is re-evaluated

// Configure Docker to start on boot sudo systemctl enable docker sudo systemctl start docker

// Check if it works docker run hello-world

Establishing a Build Environment (Ubuntu/Debian)

This section describes how to set up your local work environment to build the ViNO project.

Installing the JDK (Java 8)

sudo apt-get install openjdk-8-jdk

Installing Ant

sudo apt-get install ant ant-contrib

Installing required packages

sudo apt-get install git jq nodejs npm libxml2-utils node-less

Setting up the environment

sudo npm i -g [email protected]
sudo npm i -g [email protected]
sudo npm i -g @typescript-eslint/[email protected]
sudo npm i -g @typescript-eslint/[email protected]

Setting up Docker

sudo apt-get install apt-transport-https ca-certificates curl software-properties-common

curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -

sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable"

sudo apt-get install docker-ce

// Create the docker group and add your user sudo groupadd docker sudo usermod -aG docker <user>

// Log out and log back in so that your group membership is re-evaluated

// Configure Docker to start on boot sudo systemctl enable docker sudo systemctl start docker

// Check if it works docker run hello-world

Downloading the Source and Build

The ViNO source tree is located here https://github.com/CenturyLink-ViNO/vino-product
This document describes how to download the source tree and build the ViNO Project.

Create a working directory

mkdir product_vino
cd product_vino

Clone the ViNO-product repository:

IMPORTANT: it is HIGHLY recommended that you use Git over SSH to clone the project.

You can find more information on how to setup Git over SSH here.

If you want to proceed using Git over HTTPS instead, click here.

git clone [email protected]:CenturyLink-ViNO/vino-product.git

Checkout the 'master' branch:

cd vino-product/
git checkout master

Run the bootstrap script (do this for every terminal window that you want to use for this project).

source product.settings/bootstrap/bootstrap.sh

This will place you in the product_vino/ directory.

Execute thin to make sure that all dependencies are in place:

ant check

Now you can build.

The ant git.update is optional.

The 'ant clean-all' will clear the build directory and cause everything to get built.

ant git.update
ant clean-all
ant

The result of the build process is a compressed file (tar.gz) located in the build/bin folder:

ls build/bin/
vino-product-docker.0.0.0-YYMMDD_HHMM.tar.gz

Modifying the project

The ViNO project is a collection of repositories that are built together to create a product.

Before you start modifying the source code, first, you will need to identify which repository you want to change.

You will find a list of all repositories used by ViNO in this file:

product_vino/vino-product/product.settings/product.properties.xml

This file contains a list of repositories to checkout and build. There is also a group (shared) with definitions that usually are common to all repositories like Bitbucket URL, base clone directory, and ref (branch).

For each repository line we have:

name: name of the repository on Bitbucket
prefix: type of the repository, usually: lib, forks, components, drivers, or lib-web; it also corresponds to the directory that the repository will be cloned.
target: Ant target to build the repository - OPTIONAL: you only need to inform it if it is different from the repository name
cloneDir: clone directory - OPTIONAL: you only need to inform it if is different from ${tree.top}/${prefix}/${name}
ref: branch to clone - OPTIONAL: you only need to inform it if is different from the common branch (master)

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<repositories>
   <shared>
      <common url='[email protected]:CenturyLink-ViNO' cloneDirectory='${tree.top}' ref='master'/>
   </shared>
   <repos>
      <repository name='dev-env-public'                 prefix='tools/dev-env' target='DO-NOT-BUILD'             cloneDirectory='${tree.top}/tools/dev-env/public'/>
      <repository name='abacus-shell-libs-vino'         prefix='components'    target='abacus-shell-libs'        cloneDirectory='${tree.top}/components/abacus-shell-libs'/>
      <repository name='abacus-postgres-vino'           prefix='components'    target='abacus-postgres'          cloneDirectory='${tree.top}/components/abacus-postgres'/>
      <repository name='lib-java-webui-vino'            prefix='lib'           target='lib-java-web-ui'          cloneDirectory='${tree.top}/lib/lib-java-web-ui'/>
      <repository name='abacus-nodelib-util'            prefix='lib'           target='DO-NOT-BUILD'/>
      <repository name='jquery-fork'                    prefix='forks'         target='DO-NOT-BUILD'             cloneDirectory='${tree.top}/forks/web-jquery-fork'             ref='vino-master'/>
      <repository name='abacus-jquery-vino'             prefix='lib-web'       target='abacus-jquery'            cloneDirectory='${tree.top}/lib-web/abacus-jQuery'/>
      <repository name='twitter-bootstrap-fork-vino'    prefix='forks'         target='DO-NOT-BUILD'             cloneDirectory='${tree.top}/forks/web-bootstrap-fork'          ref='vino-master'/>
      <repository name='abacus-twitter-bootstrap-vino'  prefix='lib-web'       target='abacus-twitter-bootstrap' cloneDirectory='${tree.top}/lib-web/abacus-twitter-bootstrap'/>
      <repository name='abacus-lib-js-ots-vino'         prefix='lib-web'       target='DO-NOT-BUILD'             cloneDirectory='${tree.top}/lib-web/abacus-lib-js-ots'/>
      <repository name='vino-opensource-customizations' prefix='lib'           target='DO-NOT-BUILD'             cloneDirectory='${tree.top}/lib/vino-opensource-customizations'/>
      <repository name='vino-node-red-nodes'            prefix='components'    target='vino-node-red-nodes'/>
      <repository name='vino-core-nodes'                prefix='components'    target='vino-core-nodes'/>
      <repository name='vino-core'                      prefix='components'    target='vino-core'/>
      <repository name='vino-docker'                    prefix='components'    target='vino-docker'/>
      <repository name='vino-product'                   prefix=''              target='vino' />
   </repos>
</repositories>

Clone the ViNO-product repository using HTTPS:

If you want to proceed using Git over HTTPS instead (which is not recommended) execute:

export GIT_OVER_HTTPS=y

Clone the main project:

git clone https://github.com/CenturyLink-ViNO/vino-product.git

Checkout the 'master' branch:

cd vino-product/
git checkout master

Run the bootstrap script (do this for every terminal window that you want to use for this project).

source product.settings/bootstrap/bootstrap.sh

This will place you in the product_vino/ directory.

Now you need to edit the vino-product/product.settings/repos.properties.xml file and replace the "common url" property with the SSH URL:

<shared>
   <common url='[email protected]:CenturyLink-ViNO' cloneDirectory='${tree.top}' ref='master' />
</shared>

with the HTTS URL:

<shared>
   <common url='https://github.com/CenturyLink-ViNO' cloneDirectory='${tree.top}' ref='master' />
</shared>

Now you can build.

The ant git.update is optional.

The 'ant clean-all' will clear the build directory and cause everything to get built.

ant git.update
ant clean-all
ant

The result of the build process is a compressed file (tar.gz) located in the build/bin folder

ls build/bin/
vino-product-docker.0.0.0-YYMMDD_HHMM.taz.gz