Skip to content

Commit 15f4af4

Browse files
authored
Merge pull request #2738 from fractal-analytics-platform/2721-update-docs-about-users
Update docs about users
2 parents ee67309 + 77d74cf commit 15f4af4

File tree

3 files changed

+8
-9
lines changed

3 files changed

+8
-9
lines changed

CHANGELOG.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
**Note**: Numbers like (\#1234) point to closed Pull Requests on the fractal-server repository.
22

3-
# 2.15.8 (unreleased)
3+
# 2.15.8 (Unreleased)
44

5+
* Documentation:
6+
* Fix `Fractal Users` documentation page (\#2738).
57
* Internal
68
* Improve type hints (\#2739).
79

docs/internals/users.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Fractal Server's user model and authentication/authorization systems are powered
55
## User Model
66
<a name="user-model"></a>
77

8-
A Fractal user corresponds to an instance of the [`UserOAuth`](..//reference/fractal_server/app/models/security.md/#fractal_server.app.models.security.UserOAuth) class, with the following attributes:
8+
A Fractal user corresponds to an instance of the [`UserOAuth`](../reference/fractal_server/app/models/security.md#fractal_server.app.models.security.UserOAuth) class, with the following attributes:
99

1010
| Attribute | Type | Nullable | Default |
1111
| :--- | :---: | :---: | :---: |
@@ -15,13 +15,11 @@ A Fractal user corresponds to an instance of the [`UserOAuth`](..//reference/fra
1515
| is_active | bool | | true |
1616
| is_superuser | bool | | false |
1717
| is_verified | bool | | false |
18-
| <span style="background-color:teal;color:white">&nbsp;slurm_user&nbsp;</span> | string | * | null |
1918
| <span style="background-color:teal;color:white">&nbsp;username&nbsp;</span> | string | * | null |
20-
| <span style="background-color:teal;color:white">&nbsp;cache_dir&nbsp;</span> | string | * | null |
2119

22-
The colored attributes are specific for Fractal users, while the other attributes are [provided](https://github.com/fastapi-users/fastapi-users-db-sqlmodel/blob/main/fastapi_users_db_sqlmodel/__init__.py) by FastAPI Users.
20+
The colored attribute (`username`) is specific for Fractal users, while the other attributes are [the default ones from `fastapi-users`](https://fastapi-users.github.io/fastapi-users/latest/configuration/schemas/).
2321

24-
In the startup phase, `fractal-server` always creates a default user, who also has the superuser privileges that are necessary for managing other users.
22+
In the startup phase, `fractal-server` creates a default user, who also has the superuser privileges that are necessary for managing other users.
2523
The credentials for this user are defined via the environment variables
2624
[`FRACTAL_ADMIN_DEFAULT_EMAIL`](../configuration.md/#fractal_server.config.Settings.FRACTAL_DEFAULT_ADMIN_EMAIL) (default: `[email protected]`)
2725
and
@@ -34,7 +32,7 @@ and
3432
The most common use cases for `fractal-server` are:
3533

3634
1. The server is used by a single user (e.g. on their own machine, with the [local backend](runners/local.md)); in this case you may simply customize and use the default user.
37-
2. The server has multiple users; in this case the admin may use the default user (or another user with superuser privileges) to create additional users (with no superuser privileges). For `fractal-server` to execute jobs on a SLURM cluster (through the corresponding [SLURM backend](runners/slurm.md)), each Fractal must be associated to a cluster user via the `slurm_user` attribute (see [here](runners/slurm.md/#user-impersonation) for more details about SLURM users).
35+
2. The server has multiple users, and it is connected to a SLURM cluster. For `fractal-server` to execute jobs on the SLURM cluster each Fractal must be associated to a cluster user via additional properties defined in the [`UserSettings` table](../reference/fractal_server/app/models/user_settings.md). See [here](runners/slurm.md/#user-impersonation) for more details about SLURM users.
3836

3937
More details about user management are provided in the [User Management section](#user-management) below.
4038

fractal_server/app/models/security.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,9 @@ class UserOAuth(SQLModel, table=True):
7373
is_active:
7474
is_superuser:
7575
is_verified:
76-
slurm_user:
77-
slurm_accounts:
7876
username:
7977
oauth_accounts:
78+
settings:
8079
"""
8180

8281
__tablename__ = "user_oauth"

0 commit comments

Comments
 (0)