The Visual Builder Cloud Service Blog

Automate Visual Application's CI/CD with Visual Builder Studio

Shay Shmeltzer
Director of Product Management - Oracle

Oracle Visual Builder Studio offers an improved experience for packaging and deploying Visual Applications. We now offer declarative built-in tasks that let you package and optimize your app, deploy it (either stage or live version), and manage the data stored in the app. These declarative tasks are based on an updated set of Grunt tasks available for Visual Builder, which can also be leveraged in other CI/CD platforms.

One of the nice features of Visual Builder Studio is that it automatically creates a CI/CD pipeline for your app when you create a workspace for a new or imported app. In this blog we explain what is actually being created, so you can implement additional CI/CD flows either in VBStudio or outside.

Packaging the App

The first build step we use is the package option for Visual Application - this step processes the code from your git repository, and creates zip files that contain an optimized version of your app ready to be deployed. Under the hood we are using the vb-process-local grunt task to achieve this. We then archive the resulting artifact so they can be picked up by the next build step - the deploy step.

Package Step

Deploying the App

The deploy build job uses an Oracle Deployment step, that works together with the environments defined in your VBStudio project, to pick up the optimized app and deploy it to a target Visual Builder server. You'll see that this step allow you to specify whether the app should be in stage or publish/live mode, and indicate if you want a new database schema or to keep the existing data in the business objects used. This steps uses the vb-deploy grunt task to deploy the artifacts created before.

Deploy Step

Once the jobs are in place you can streamline their execution by including them as part of a pipeline:

Deployment pipeline

Using Grunt Directly

In the video I'm also showing how you can use the same grunt tasks as part of a shell script to do deployment. You can use this approach if you want to package and deploy directly from your machine, or from external CI/CD systems.

The script used is:

npm install
grunt vb-archive:sources --sources-zip-path=build/sources.zip vb-process-local vb-package vb-archive:optimized --optimized-zip-path=build/built-assets.zip
grunt vb-deploy --url=https://yourserver/ic/builder/ --username=youruser --password=$pass

To learn more about the grunt tasks Visual Builder provides, see our grunt tasks doc.

Here is a demo of the end-to-end flow:

Once your app is deployed, you might need to load data into the business objects that it uses - which are going to be empty initially. You can learn more about doing this with the import data build tasks described in this blog.

Join the discussion

Comments ( 1 )
  • Muhammad N Ahmed Wednesday, November 11, 2020
    Shay, This great info. I been stumbling over it from a couple of days now. Thanks for your all your videos. Please keep 'em coming.
Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.