Deploying Your Saito Application

Option #1: Upload to Network Appstore

To upload your application to an Appstore, you must create a ZIP file that contains the code. This ZIP file should contain a single directory named after your application that contains all of its files. If you aren’t sure what this means, read through our tutorials to see.

Now visit Saito Email in your browser and click on “AppStore” in the application menu. Scroll to the Developer section and click on “Publish Application”. Select the ZIP file from your harddrive and click on the “Submit” button that will appear once your browser has loaded this ZIP file into memory.

Congratulations. Your App is published.

What has technically happened is that your browser has signed your application and broadcast it as part of a specially-formatted transaction. The AppStores on the Saito network will receive this application and index it for users to download and install. You will also be sent an email with the unique APP-ID of your application, and a link you can share with others to download and install it.

If you run into any problems, the most likely cause is a software error in your code: AppStores will not publish or index material that does not compile. In this case, it can be useful to setup a local version of Saito and install your module locally to make sure it works.

Option #2: Installing Locally

Go through the normal process of installing Saito on your computer. Make sure you are using a compatible version of NodeJS ( > 12 ) and have run “npm install” and “npm run nuke” so you are dealing with a fresh install.

Copy your module into the Saito module directory (/mods). Now edit your module configuration file so that your local Saito install loads it on start. The file you want to edit here is /config/modules.config.js. If that file does not exist you can edit /config/modules.default.js instead. The default file is copied over into the standard configuration file on setup if the standard configuration file is missing.

Remember that there are two sections in the config file [core, lite]. The first section [core] defines which modules will run on your server. The second section [lite] defines which modules will be compiled into the standard javascript bundle that is served to lite-clients. You probably want to add your module to both.

Nuke your setup (“npm run nuke”), look for error messages in the compilation process, fix them, and rinse and repeat until you are OK to run Saito (“npm run”) and test out your module locally.