Compliant Kubernetes Service documentation has moved

Please note: You are not reading Kubernetes documentation. If you're looking for Compliant Kubernetes Service documentation, it has moved. Read more here.

To run Parse applications on Datica CPaaS, you will need to install the Parse Dashboard in your environment. This guide outlines the steps required to do so.

Once you have a Parse Dashboard set up, our guide for adding new Parse applications explains how to deploy a new Parse application and link it into your dashboard.

 

Variables

The steps below will set up and configure a Parse Dashboard for use with the example application configured in our Parse application setup guide. The following variables used in this guide should be replaced with values specific to your environment:

Variable Description
<env-name> Replace with the name of your environment (e.g. "myapp-staging")
<parse-dashboard-fqdn>  Replace with the fully qualified domain name for your Parse dashboard (e.g. "parse-dashboard.example.com")
 <parse-dashboard-username>  User name for authentication to the Parse dashboard
<password> Password for the Parse dashboard

 

Steps

1. Add the Parse Dashboard Code Service

Add a new code service to your environment with the following parameters:

Name: parse-dashboard
Scale: 1
Worker Scale: 0
RAM (GB): 1
CPU: 1

IMPORTANT: The remainder of these instructions assume that your service is created with the above settings.

2. Configure the Parse Dashboard Code Repository

Clone Datica's Parse server repository and configure it to push to your new code service:

(In the following commands, replace <env-name> with the name of your CPaaS environment)

git clone git@github.com:catalyzeio/stratum-parse-dashboard.git <env-name>-parse-dashboard
cd <env-name>-parse-dashboard
git remote remove origin
datica -E <env-name> init

When running datica init, use the environment and code service name you added in step 1 to configure the repository.

 

3. Configure Environment Variables

Use the Datica CLI to add the following environment variable to the parse-dashboard code service:

datica -E <env-name> vars set parse-dashboard -v PARSE_DASHBOARD_CONFIG=/app/config.json

 

4. Update config.json

In your local repository, update config.json to include the user name and password you wish to use to authenticate to the Parse Dashboard. Make sure you commit your changes.

Example (remove the "!" from the code below after you add your user and password):

{
   "apps": [
{
}
   ],
   "users": [
      {
           !"user": "<parse-dashboard-username>",
           !"pass": "<password encrypted with bcrypt>"
       }
   ],
   "useEncryptedPasswords": true
}

If you already have a Parse application deployed in your environment, you can add the application to the Parse Dashboard by following the guide "Add a Parse application to the Parse Dashboard".

For additional settings that can be configured in config.json, refer to the Parse documentation at https://github.com/parse-community/parse-dashboard#configuring-parse-dashboard

 

5. Configure the Service Proxy

IMPORTANT: Before completing this step, ensure that you have created a DNS CNAME record for <parse-dashboard.fqdn> that points to your service proxy, as described in the DNS Setup Guide.

In order to access the Parse Dashboard, it must be exposed through the environment's service proxy. The following steps will create a new site definition and associate it with the code service you created in step 1. This example uses LetsEncrypt for TLS security.

datica -E "<env-name>" sites create <parse-dashboard-fqdn> parse-dashboard --lets-encrypt

Once created, the site will be accessible at https://<parse-dashboard-fqdn>.

 

6. Deploy the Parse Dashboard

Deploy the dashboard by pushing your local repository to the code service you created in step 1:

cd /path/to/<env-name>-parse-dashboard

git push datica master

Once the service deploys, you should be able to log into the dashboard at "/dashboard/login" via the site you added to your service proxy in step 5.