Applications created on NodeRun can be exported and run in Profound.js.
Exporting a NodeRun Workspace
To export a NodeRun workpace, right-click on Workspace Files in the Files tree in the NodeRun IDE and select Download Zip.
The ZIP file will include a directory that is named after the workspace.
Installing a New Profound.js Server with the Workspace
If the workspace start program is a Profound.js module or the workspace has Profound.js web service routes, the directory contents will look like below. In this example, a workspace created using the Rest Web Services template was exported:
The directory contains a package.json that can be used by NPM to install Profound.js. The 'modules' directory includes a sub-directory named 'app' which includes all of the workspace files, including the workspace Git repository:
To run the workspace in a new Profound.js installation, extract the contents of the ZIP to your desired PC or server and run npm install from within the top-level directory. This will install a copy of Profound.js in the directory. See Installation for more information on the installation process and server configuration.
Installing a Workspace in an Existing Profound.js Server
To run a workspace containing Profound.js programs in an existing Profound.js installation, place a copy of the 'app' directory into the 'modules' directory of the Profound.js server. The 'app' directory can be renamed, if desired. The Profound.js server will automatically load the workspace the next time it is restarted.
Installing a non-Profound.js Workspace in an Existing Profound.js Server
This type of workspace can only be installed in an existing Profound.js server. To install, copy the top-level directory into the Profound.js server's 'modules' directory. The directory can be renamed, if desired. The Profound.js server will automatically load the workspace the next time it is restarted.
NodeRun workspaces come with a built-in MariaDB (MySQL) database that is only accessible from workspaces running on NodeRun.com. To run a workspace that uses the database in Profound.js, you'll need to set up an instance of MariaDB or MySQL that Profound.js can connect to, and configure the 'mysql' database driver. See dbDriver for database driver configuration details.
Running the Workspace
Once the workspace is installed, the workspace can be launched using a URL path that matches the workspace directory name in 'modules'. For example, if the default directory name 'app' is used, then the workspace start file can be launched with a URL like this:
Web service routes can be run by appending the route path to the URL above. For example, to run a web service with route path 'list':
Configuring Workspace Settings
The Profound.js Designer is aware of NodeRun workspaces and can be used to edit the workspace's app start file, and to edit web service routes. To edit settings, click right-click on the desired file in the Designer's Files tree and select Properties.
Settings changed in the File Properties dialog will be saved to the workspace's 'settings.json' file and will be effective immediately.
Deploying Changes to NodeRun.com
Changes made to a NodeRun workspace with Profound.js can be deployed to NodeRun.com via GitHub. If the NodeRun workspace was setup on or cloned from GitHub, changes can be pushed from the Profound.js Designer to GitHub. See Git Integration for information on using Git in the Profound.js Designer.
Changes can then be manually pulled from GitHub into the NodeRun IDE, or the workspace can be configured to automatically sync with GitHub so that it performs an automatic pull when changes are pushed to GitHub. See the NodeRun docs for information on using Git in the NodeRun IDE.