
signageOS aims to enable developers to easily integrate and deploy devices with effective and logical Documentation for assistance. To do this, we consistently update the Documentation to reflect the feedback we receive from partners. One of the most recent updates is step-by-step instructions on setting up your developer environment using the signageOS CLI for easy development. View the tutorial below:
In just 4 steps, you can ship your custom application to any of signageOS’ supported devices:
- Install signageOS CLI
- Start your project in any IDE
- Build your application
- Ship your application
So, what will you need?
- signageOS account
- At least one organization in the signageOS Box (device management console)
- Node.js >= 10.15.0
- NPM
- Shell, Gitbash, Powershell
Create a signageOS account here and check out the FAQ for more information on organizations. NPM (Node Package Manager) manages Node.js packages or modules which contain all of the files you need for your libraries in your project. Shell, Gitbash, and Powershell are examples of command-line shells that are used to interface with an operating system through written commands.
Download and install Node.js. Node.js will run as a background process so after installation, there are no other steps that are needed to take with Node.js.
Download and install Shell, Gitbash, or Powershell. Once downloaded open the command-line shell and follow with the next steps below.
This process uses one of the most recently introduced features to aid in development, a CLI. The purpose of the CLI is to allow interaction with the signageOS Cloud and signageOS APIs for ease of development and greater efficiency. Advanced users can utilize the signageOS Emulator and CLI to rapidly integrate signageOS into their stack and test without using the signageOS GUI environment. Read more about the CLI here.
1. Install the signageOS CLI
Using your command-line shell (Shell, Gitbash, Powershell), download the signageOS CLI by entering the following:
Once installed, enter sos --help for quick help commands within the CLI. Login to your signageOS account from the CLI using the CLI command sos login then set your default organization using sos organization set-default. Organizations can be created within the device management console. Next, create your Applet (HTML5 application) using the command sos applet generate. An applet includes your application code along with the signageOS JS API to create a standardized environment for your code to run on numerous device platforms. You will name the Applet after it is generated.
2. Start your project in any IDE
Once the Applet is successfully created, switch to the project folder and start the project by entering npm start. This command will trigger NPM and run it in the background. By running npm start you will get the URL (e.g.: http://your.pc.ip.address:8090) where your code is running. Your project is now successfully created and running on http://your.pc.ip.address:8090. It is easy to debug your code so far from within the browser using the browser’s built-in code inspector.You can open the URL in your browser (preferable Chrome) and start your development in the web IDE or open it for local development using your downloaded IDE like VScode, NetBeans, etc.
3. Build your application
Now, build the Applet (HTML5 application) to meet your desired application behaviour needs. Once you are satisfied with your application run the following command: npm run build. This command automatically gathers of the code and bundles it together in a way that the signageOS Core Apps (core applications developed for every supported platform) will understand. The final code can be found in the /dist directory.
Once the build is successful, upload your code to signageOS with the following command: sos applet upload.
Why do you need to upload the code to the signageOS Cloud? Because signageOS will build the Core Apps for each and every platform for you. The Applet you built needs to be ran inside the Core App. As building Core Apps is under signageOS’ NDA and development agreements, we do that for you securely in our cloud. You just push your code and we deliver the final Core Apps.
4. Ship your application
Now you are ready to ship the application. The steps to shipping the application will depend on the type of subscription you have with signageOS: Open or Platform. The differences in shipping the application with signageOS Open and Platform can be found here and are clearly communicated to further assist in development.
Setting up the developer environment is now completed! You can now start your development easily, locally and with your preferred IDE for more efficient development with signageOS. Is there a feature that would greater assist you in this process? Let us know. We strive to improve processes to make your digital signage development as easy as possible.