Skip to content

Commit

Permalink
+Two new CLI commands and env vars for imports on startup
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhghomon committed Dec 12, 2024
1 parent f11239a commit 1f38583
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/content/doc-surrealdb/cli/env.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,11 @@ Environment variables can be used to tailor the behaviour of a running SurrealDB
<td scope="row" data-label="Default">4398046511104 (4 GiB)</td>
<td scope="row" data-label="Notes">Maximum HTTP body size of the HTTP /import endpoints</td>
</tr>
<tr>
<td scope="row" data-label="Env var"><code>SURREAL_IMPORT_FILE</code></td>
<td scope="row" data-label="Default">None</td>
<td scope="row" data-label="Notes">Path to a SurrealQL file that will be imported when starting the server.</td>
</tr>
<tr>
<td scope="row" data-label="Env var"><code> SURREAL_INSECURE_FORWARD_ACCESS_ERRORS </code></td>
<td scope="row" data-label="Default">false</td>
Expand Down Expand Up @@ -143,6 +148,11 @@ Environment variables can be used to tailor the behaviour of a running SurrealDB
<td scope="row" data-label="Default">Number of CPUs on the current device</td>
<td scope="row" data-label="Notes">Size of the SurrealCS connection pool.</td>
</tr>
<tr>
<td scope="row" data-label="Env var"><code>SURREAL_TEMPORARY_DIRECTORY</code></td>
<td scope="row" data-label="Default">None</td>
<td scope="row" data-label="Notes">Sets the directory for storing temporary database files.</td>
</tr>
<tr>
<td scope="row" data-label="Env var"><code>SURREAL_TRANSACTION_CACHE_SIZE</code></td>
<td scope="row" data-label="Default">10000</td>
Expand Down
18 changes: 18 additions & 0 deletions src/content/doc-surrealdb/cli/start.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,15 @@ The start command starts a SurrealDB server in memory, on disk, or in a distribu
Sets the hostname or IP address to listen for connections on
</td>
</tr>
<tr>
<td colspan="2">
`--import-file`
<Label label="optional" />
</td>
<td>
Path to a SurrealQL (`.surql`) file that will be imported when starting the server
</td>
</tr>
<tr>
<td colspan="2">
`-l` / `--log`
Expand Down Expand Up @@ -168,6 +177,15 @@ The start command starts a SurrealDB server in memory, on disk, or in a distribu
Sets whether strict mode is enabled on this database instance
</td>
</tr>
<tr>
<td colspan="2">
`--temporary-directory`
<Label label="optional" />
</td>
<td>
Sets the directory for storing temporary database files
</td>
</tr>
</tbody>
</table>
</TabItem>
Expand Down

0 comments on commit 1f38583

Please sign in to comment.