Self-host your RudderStack control plane using Control Plane Lite.
4 minute read
RudderStack’s control plane provides a UI to manage your source and destination configurations.
You can use the Control Plane Lite utility to self-host your control plane. Control Plane Lite lets you manage your data pipelines locally by exporting or importing your configurations from a JSON file.
Open your terminal and navigate to the Config Generator folder. Then, run the following commands:
npm install
npm start
After the setup is complete, you can access the dashboard at http://localhost:3000.
Export workspace configuration
Set up your connections by adding the sources and destinations in the dashboard.
Click the EXPORT button on the top right to export your workspace configuration as a JSON file.
RudderStack requires this JSON file (workspaceConfig.json) to start the RudderStack server.
Data plane setup and usage
Depending on your setup environment, follow the steps in the below sections to start the RudderStack server (data plane) using the exported workspace configuration file.
Replace <workspace_config_filepath_in_container> in the above line with your container file path. By default, you can set it to /etc/rudderstack/workspaceConfig.json.
In the volumes section under the backend service, uncomment the following line:
Replace <absolute_path_to_workspace_config> with the local path of your workspaceConfig.json(where your workspace configuration file is saved locally). Also, replace <workspace_config_filepath_in_container> with the container file path set in Step 3.
The value for <workspace_config_filepath_in_container> should be exactly as the value you set for the RSERVER_BACKEND_CONFIG_CONFIG_JSONPATH variable. Otherwise, your workspace configuration will not be loaded, and you will get an error.
Navigate to the directory where the RudderStack data plane (rudder-server) is installed and run the following command:
createdb jobsdb
createuser --superuser rudder
psql "jobsdb" -c "alter user rudder with encrypted password 'rudder'";psql "jobsdb" -c "grant all privileges on database jobsdb to rudder";
Go to the dashboard, set up your source, and export the source configuration by clicking the EXPORT SOURCE CONFIG button:
Host the exported file on your server such that it can be accessed via the path <CONTROL_PLANE_URL>/sourceConfig.
Provide the base URL of your server (<CONTROL_PLANE_URL>) serving this file in your SDK initialization code snippet. For more information on SDK initialization, see the following sections in the respective SDK guides:
The RudderStack SDKs automatically append /sourceConfig to the base server URL to fetch the configuration. For example, {CONTROL_PLANE_URL}/sourceConfig.
A sample source configuration exported from the dashboard:
{"source":{"config":{},"id":"1im8yfXQsocRBGcQLXAaq5M8dYV","name":"test-JS","writeKey":"1im8yk2sz8oyHVCGVqViSNfKVDF","enabled":true,"sourceDefinitionId":"1TW48i2bIzEl1HPf825cEznfIM8","deleted":false,"createdAt":"Mon Oct 12 2020 16:51:54 GMT+0530 (India Standard Time)","updatedAt":"Mon Oct 12 2020 16:51:54 GMT+0530 (India Standard Time)","sourceDefinition":{"id":"1TW48i2bIzEl1HPf825cEznfIM8","name":"JavaScript","displayName":"JavaScript","category":null,"createdAt":"2019-11-12T12:39:19.885Z","updatedAt":"2020-06-18T11:54:06.114Z"},},"metadata":{"version":"1.0.2"}}
This site uses cookies to improve your experience while you navigate through the website. Out of
these
cookies, the cookies that are categorized as necessary are stored on your browser as they are as
essential
for the working of basic functionalities of the website. We also use third-party cookies that
help
us
analyze and understand how you use this website. These cookies will be stored in your browser
only
with
your
consent. You also have the option to opt-out of these cookies. But opting out of some of these
cookies
may
have an effect on your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This
category only includes cookies that ensures basic functionalities and security
features of the website. These cookies do not store any personal information.
This site uses cookies to improve your experience. If you want to
learn more about cookies and why we use them, visit our cookie
policy. We'll assume you're ok with this, but you can opt-out if you wish Cookie Settings.