Instructions for creating & connecting to a Data Source
1. Open a previously created environment by double clicking on it from the Data Environments page in the Library.
2. Create a new Data Source in the environment by clicking on (+) next to DATA SOURCES.
3. Enter a name and select a type for the Data Source. Supported database servers include Oracle, PostgreSQL, MYSQL, OSI Pi, and MS SQL (Microsoft SQL Server). Connection settings (encrypted protocols) should also be entered.
4. To create an encrypted configuration string, ssh into any Riffyn Data Agent in the environment of the Data Source, and use the generate-secure-config utility on the Data Agent to prompt for the required connection information. The utility will then produce the encrypted connection string, which can be saved into the Create Data Source modal in the Riffyn UI.
$ cd /srv/riffyn/agent/
Follow the user prompts to create an encrypted configuration string for the data source
Config inputs: Enter Riffyn Agent plugin name: PostgreSQL
Config inputs: Enter path to RSA key file to encrypt the config:
Please enter the PostgreSQL connection information:
Config inputs: Enter pg server host name or IP address: 192.168.22.22
Config inputs: Enter TCP port number for the pg server: (5432) 5432
Config inputs: Enter pg user name with read-only access: view-user
Config inputs: Enter password associated with the pg user name:
Config inputs: Enter pg database name: test
Config inputs: Does server requires encrypted connections (SSL)?: (false) true
Config inputs: Enter client encoding to use for the pg connection:
Config inputs: Enter application name for the pg connection:
Encrypted datasource configuration:
5. Copy and paste the encrypted string (containing the Data Source connection information) into the data source creation modal in the Riffyn application. This ensures that other agents added to this environment will be able to access all data sources in that environment.
Click Create to save the Data Source.
6. Click on the ellipsis menu next to the new data source and select Refresh Metadata to retrieve a list of database tables available for queries.
7. The Data Source is now ready for use on any experiment by anyone who has been shared access to this Data Environment.