SFTP
Connect an SFTP server so Qubit can load CSV files from it on a schedule. You decide which files go into which table.
Before you start
- Create an SFTP user for Qubit that can read the folders holding your files. Qubit signs in with a user name and password; the form has no field for an SSH key.
- Make sure the server accepts connections from Qubit's servers on its SFTP port.
- Decide how files map to tables. For each table, you need a folder to search and a pattern that matches the file names.
Connect SFTP
- Open Data Catalog from the sidebar, click Add Data, then choose Connect a database.
- On the New Data Source page, click SFTP. It is under Cloud Storage.
- Enter a Connection Name.
- Fill in the fields:
- Host: the server's hostname or IP address.
- Port: defaults to
22. - Username and Password: the SFTP user.
- Load files modified since: files last modified before this date are skipped. Defaults to January 1, 2020.
- Tables (JSON): required. A JSON list with one entry per table. Each entry has a
table_name, asearch_prefix(the folder to search, including its subfolders), and asearch_pattern(a regular expression matched against the full file path). You can also setdelimiterandencoding. For example:[{"table_name": "orders", "search_prefix": "/upload/orders", "search_pattern": "\\.csv$"}].
- Choose a Sync Schedule. The default is Daily.
- Click Create.
If the Tables (JSON) value is not valid JSON, the form shows an error before saving.
After you connect
Qubit saves the connection and starts the first sync. It confirms that it can sign in and find files during that sync.
To check the connection at any time, open its menu in the Data Catalog and choose Test connection. If Last sync shows Failed, hover over it to see the reason, correct the details with Edit, then choose Sync now.