You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Building a Bolt‑Based Web Application

To build a Bolt‑based web application, you will need the following:

  • Bolt Tools
  • App package configuration
  • Certificates for signing the app bundle

1. Bolt Tools

Install and set up bolt-tools on your system by following the instructions in the repository:

https://github.com/rdkcentral/bolt-tools/tree/main

Bolt Tools provides the utilities required to package and sign your Bolt applications.



2. App Package Configuration

The app package configuration defines the entry point, dependencies, permissions, and other metadata required for building the Bolt package.

2.1 Key Fields:

  • Entry Point
    For a web application, the entry point should be the URL that the WPE WebKit browser should load.
    Example: "--url=https://lightningjs.io/tmdb/#splash"

  • Dependencies:
    Specify the runtime and base Bolt packages your app depends on.
    For web apps, you must include the WPE browser package and its appropriate version.
    Example: "com.rdkcentral.wpe-rdk": "0.1.0"
    

  • Permissions:
    Permissions required by the container, such as:
    • internet
    • thunder
    • firebolt
    • rialto

Sample App Configuration (JSON)

{
  "id": "com.rdkcentral.tmdb",
  "version": "0.1.0",
  "versionName": "develop",
  "name": "tmdb",
  "packageType": "application",
  "entryPoint": "--url=https://lightningjs.io/tmdb/#splash",
  "dependencies": {
    "com.rdkcentral.wpe-rdk": "0.1.0"
  },
  "permissions": [
    "urn:rdk:permission:internet",
    "urn:rdk:permission:firebolt",
    "urn:rdk:permission:thunder",
    "urn:rdk:permission:rialto"
  ],
  "configuration": {}
}


3. Creating a Bolt Package

To package an HTML/Lightning app into a Bolt bundle, you need:

  1. A JSON configuration file (com.rdkcentral.app_name.json)
  2. A rootfs layer in .tgz format

For HTML/Lightning applications, the rootfs layer can be an empty .tgz file, since the app is launched via a browser using a URL.

Steps

  1. Create an empty .tgz file, e.g.:
    empty.tgz
    
  2. Create your App Package configuration JSON file.
  3. Run the Bolt pack command:
    bolt pack com.rdkcentral.app_name.json empty.tgz
    
  4. The command will generate:
    com.rdkcentral.app_name+<version>.bolt
    
    This is the Bolt package to be installed on the platform.

4. Signing Your Bolt App

Every Bolt app must be digitally signed before installation.

Follow the signing instructions here:
https://wiki.rdkcentral.com/spaces/RDKM/pages/447124247/Bolt+package+-+signing+and+verification


5. Sideloading the Bolt App to the Platform

  1. Copy/SCP the .bolt package to the device, for example:
    /tmp/com.rdkcentral.app_name+0.1.0.bolt
    
  2. Install the app using the PackageManager.
  3. Launch the app using the Application Manager.


  • No labels