Skip to content

Commit c933ea9

Browse files
Merge branch 'sqlpage:main' into success_stories
2 parents 6e2bc34 + 0994b92 commit c933ea9

10 files changed

Lines changed: 357 additions & 252 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
# CHANGELOG.md
22

3+
## unreleased
4+
- OIDC protected and public paths now respect the site prefix when it is defined.
5+
36
## 0.42.0 (2026-01-17)
47

58
- **New Function**: `sqlpage.web_root()` - Returns the web root directory where SQLPage serves `.sql` files from. This is more reliable than `sqlpage.current_working_directory()` when you need to reference the location of your SQL files, especially when the `--web-root` argument or `WEB_ROOT` environment variable is used.

Cargo.lock

Lines changed: 44 additions & 44 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -175,17 +175,6 @@ To run on a server, you can use [the docker image](https://hub.docker.com/r/lova
175175
We provide compiled binaries only for the x86_64 architecture, but provide docker images for other architectures, including arm64 and armv7. If you want to run SQLPage on a Raspberry Pi or
176176
a cheaper ARM cloud instance, using the docker image is the easiest way to do it.
177177

178-
#### DuckDB ODBC Docker Image
179-
180-
A DuckDB-enabled variant is available with pre-installed DuckDB ODBC drivers:
181-
182-
- Use the `-duckdb` suffix: `lovasoa/sqlpage:main-duckdb` or `lovasoa/sqlpage:latest-duckdb`
183-
- Comes pre-configured to connect to DuckDB at `/var/lib/sqlpage/duckdb.db`
184-
- To use a custom database location, set `DATABASE_URL`:
185-
- `docker run -e DATABASE_URL="Driver=DuckDB;Database=/path/to/your.db" -p 8080:8080 lovasoa/sqlpage:main-duckdb`
186-
- To persist your DuckDB database, mount a volume:
187-
- `docker run -v ./data:/var/lib/sqlpage lovasoa/sqlpage:main-duckdb`
188-
189178
### On Mac OS, with homebrew
190179

191180
An alternative for Mac OS users is to use [SQLPage's homebrew package](https://formulae.brew.sh/formula/sqlpage).
@@ -205,6 +194,13 @@ You still need to install or provide the database-specific ODBC driver for the d
205194

206195
#### Install your ODBC database driver
207196
- [DuckDB](https://duckdb.org/docs/stable/clients/odbc/overview.html)
197+
- If you use docker, a DuckDB-enabled image variant is available with pre-installed DuckDB ODBC drivers
198+
- Use the `-duckdb` suffix: `lovasoa/sqlpage:main-duckdb` or `lovasoa/sqlpage:latest-duckdb`
199+
- Comes pre-configured to connect to DuckDB at `/var/lib/sqlpage/duckdb.db` inside the container
200+
- To customize [connection options](https://duckdb.org/docs/stable/clients/odbc/configuration), set `DATABASE_URL`:
201+
- `docker run -e DATABASE_URL="Driver=DuckDB;Database=/path/to/your.db" -p 8080:8080 lovasoa/sqlpage:main-duckdb`
202+
- To persist your DuckDB database, mount a volume:
203+
- `docker run -v ./data:/var/lib/sqlpage lovasoa/sqlpage:main-duckdb`
208204
- [Snowflake](https://docs.snowflake.com/en/developer-guide/odbc/odbc)
209205
- [BigQuery](https://cloud.google.com/bigquery/docs/reference/odbc-jdbc-drivers)
210206
- For other databases, follow your database's official odbc install instructions.

configuration.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ Here are the available configuration options and their default values:
2525
| `configuration_directory` | `./sqlpage/` | The directory where the `sqlpage.json` file is located. This is used to find the path to [`templates/`](https://sql-page.com/custom_components.sql), [`migrations/`](https://sql-page.com/your-first-sql-website/migrations.sql), and `on_connect.sql`. Obviously, this configuration parameter can be set only through environment variables, not through the `sqlpage.json` file itself in order to find the `sqlpage.json` file. Be careful not to use a path that is accessible from the public WEB_ROOT |
2626
| `allow_exec` | false | Allow usage of the `sqlpage.exec` function. Do this only if all users with write access to sqlpage query files and to the optional `sqlpage_files` table on the database are trusted. |
2727
| `max_uploaded_file_size` | 5242880 | Maximum size of forms and uploaded files in bytes. Defaults to 5 MiB. |
28-
| `oidc_protected_paths` | `["/"]` | A list of URL prefixes that should be protected by OIDC authentication. By default, all paths are protected (`["/"]`). If you want to make some pages public, you can restrict authentication to a sub-path, for instance `["/admin", "/users/settings"]`. |
29-
| `oidc_public_paths` | `[]` | A list of URL prefixes that should be publicly available. By default, no paths are publicly accessible (`[]`). If you want to make some pages public, you can bypass authentication for a sub-path, for instance `["/public/", "/assets/"]`. Keep in mind that without the closing backslashes, that any directory or file starting with `public` or `assets` will be publicly available. This will also overwrite any protected path restriction. If you have a private path `/private` and you define the public path `/private/public/` everything in `/private/public/` will be publicly accessible, while everything else in private will still need authentication.
28+
| `oidc_protected_paths` | `["/"]` | A list of URL prefixes that should be protected by OIDC authentication. By default, all paths are protected (`["/"]`). If you want to make some pages public, you can restrict authentication to a sub-path, for instance `["/admin", "/users/settings"]`. All paths must start with a "/" and will be prepended by `site_prefix` if defined.|
29+
| `oidc_public_paths` | `[]` | A list of URL prefixes that should be publicly available. By default, no paths are publicly accessible (`[]`). If you want to make some pages public, you can bypass authentication for a sub-path, for instance `["/public/", "/assets/"]`. Keep in mind that without the closing backslashes, that any directory or file starting with `public` or `assets` will be publicly available. This will also overwrite any protected path restriction. If you have a private path `/private` and you define the public path `/private/public/` everything in `/private/public/` will be publicly accessible, while everything else in private will still need authentication. All paths must start with a "/" and will be prepended by `site_prefix` if defined.
3030
| `oidc_issuer_url` | | The base URL of the [OpenID Connect provider](#openid-connect-oidc-authentication). Required for enabling Single Sign-On. |
3131
| `oidc_client_id` | sqlpage | The ID that identifies your SQLPage application to the OIDC provider. You get this when registering your app with the provider. |
3232
| `oidc_client_secret` | | The secret key for your SQLPage application. Keep this confidential as it allows your app to authenticate with the OIDC provider. |

examples/official-site/assets/highlightjs-and-tabler-theme.css

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
/* Code colors */
2727
--tblr-code-color: hsl(225deg 45.4% 76.93%); /* Light code text for dark theme */
2828
--tblr-code-bg: hsla(225, 47%, 15%, 0.5); /* Subtle dark background */
29+
--tblr-active-bg: var(--tblr-code-bg);
2930

3031
/* Ethereal accent colors */
3132
--tblr-blue-rgb: 84, 151, 213;
@@ -36,6 +37,26 @@
3637
--tblr-primary: rgb(var(--tblr-primary-rgb));
3738
--tblr-secondary: hsla(247, 60%, 94%, 0.7); /* Nebula purple */
3839

40+
/* Status + accent colors aligned with the brand palette */
41+
--tblr-success-rgb: 16, 132, 86; /* Deep green for white text */
42+
--tblr-success: rgb(var(--tblr-success-rgb));
43+
--tblr-warning-rgb: 197, 124, 0; /* Deep amber */
44+
--tblr-warning: rgb(var(--tblr-warning-rgb));
45+
--tblr-danger-rgb: 196, 68, 68; /* Deep crimson */
46+
--tblr-danger: rgb(var(--tblr-danger-rgb));
47+
--tblr-purple-rgb: 118, 82, 200; /* Deep violet */
48+
--tblr-purple: rgb(var(--tblr-purple-rgb));
49+
--tblr-cyan-rgb: 0, 149, 168; /* Deep cyan */
50+
--tblr-cyan: rgb(var(--tblr-cyan-rgb));
51+
--tblr-indigo-rgb: 96, 113, 215; /* Deep indigo */
52+
--tblr-indigo: rgb(var(--tblr-indigo-rgb));
53+
--tblr-teal: #267d63;
54+
--tblr-teal-fg: #20050b;
55+
56+
--tblr-green: var(--tblr-success);
57+
--tblr-yellow: var(--tblr-warning);
58+
--tblr-red: var(--tblr-danger);
59+
3960
/* Luminous links */
4061
--tblr-link-color: hsl(212, 70%, 75%) !important; /* Star glow */
4162
--tblr-link-hover-color: hsl(212, 70%, 85%) !important; /* Supernova */
@@ -62,6 +83,26 @@
6283
--hljs-cosmic-keyword: hsl(210, 100%, 75%); /* Blue giant */
6384
}
6485

86+
.btn-primary {
87+
--tblr-btn-border-color: var(--tblr-secondary);
88+
--tblr-btn-active-border-color: transparent;
89+
--tblr-btn-color: var(--tblr-primary-fg, #ffffff);
90+
--tblr-btn-bg: transparent;
91+
--tblr-btn-hover-color: var(--tblr-primary-fg);
92+
--tblr-btn-hover-bg: transparent;
93+
--tblr-btn-active-color: var(--tblr-primary-fg);
94+
--tblr-btn-active-bg: transparent;
95+
--tblr-btn-disabled-bg: var(--tblr-primary);
96+
--tblr-btn-disabled-color: var(--tblr-primary-fg);
97+
--tblr-btn-box-shadow: 0.1em 0.1em 0.1em var(--tblr-primary);
98+
--tblr-btn-hover-border-color: var(--tblr-primary);
99+
--tblr-btn-active-shadow: -0.1em -0.1em 0.1em var(--tblr-primary);
100+
}
101+
102+
.dropdown-menu {
103+
--tblr-dropdown-link-active-color: rgb(166, 211, 255);
104+
}
105+
65106
@media (min-width: 768px) {
66107
.layout-boxed {
67108
background: #07020ff5

0 commit comments

Comments
 (0)