Profile
| CLASS | DESCRIPTION |
|---|---|
ProfileRead |
Profile schema for GET endpoints. |
ValidProfileLocal |
Valid local profile. |
ValidProfileSlurmSSH |
Valid SLURM/sudo profile. |
ValidProfileSlurmSudo |
Valid SLURM/sudo profile. |
| FUNCTION | DESCRIPTION |
|---|---|
cast_serialize_profile |
Cast/serialize round-trip for |
Attributes¶
Classes¶
ProfileRead
pydantic-model
¶
Bases: BaseModel
Profile schema for GET endpoints.
| ATTRIBUTE | DESCRIPTION |
|---|---|
id |
TYPE:
|
name |
TYPE:
|
resource_id |
TYPE:
|
resource_type |
TYPE:
|
username |
TYPE:
|
ssh_key_path |
TYPE:
|
jobs_remote_dir |
TYPE:
|
tasks_remote_dir |
TYPE:
|
pixi_cache_dir |
TYPE:
|
Fields:
-
id(int) -
name(str) -
resource_id(int) -
resource_type(str) -
username(str | None) -
ssh_key_path(str | None) -
jobs_remote_dir(str | None) -
tasks_remote_dir(str | None) -
pixi_cache_dir(str | None)
Source code in fractal_server/app/schemas/v2/profile.py
ValidProfileLocal
pydantic-model
¶
Bases: BaseModel
Valid local profile.
| ATTRIBUTE | DESCRIPTION |
|---|---|
name |
Profile name.
TYPE:
|
resource_type |
Type of the corresponding resource.
TYPE:
|
Fields:
-
name(NonEmptyStr) -
resource_type(ResourceType) -
username(None) -
ssh_key_path(None) -
jobs_remote_dir(None) -
tasks_remote_dir(None) -
pixi_cache_dir(None)
Source code in fractal_server/app/schemas/v2/profile.py
ValidProfileSlurmSSH
pydantic-model
¶
Bases: BaseModel
Valid SLURM/sudo profile.
| ATTRIBUTE | DESCRIPTION |
|---|---|
name |
Profile name.
TYPE:
|
resource_type |
Type of the corresponding resource.
TYPE:
|
username |
SLURM user to impersonate (e.g. as in
TYPE:
|
ssh_key_path |
Local path of SSH private key for user
TYPE:
|
tasks_remote_dir |
Base folder for task environments on the remote SLURM cluster.
TYPE:
|
jobs_remote_dir |
Base folder for job directories on the remote SLURM cluster.
TYPE:
|
pixi_cache_dir |
Optional override for
TYPE:
|
Fields:
-
name(NonEmptyStr) -
resource_type(ResourceType) -
username(NonEmptyStr) -
ssh_key_path(AbsolutePathStr) -
jobs_remote_dir(AbsolutePathStr) -
tasks_remote_dir(AbsolutePathStr) -
pixi_cache_dir(AbsolutePathStr | None)
Source code in fractal_server/app/schemas/v2/profile.py
ValidProfileSlurmSudo
pydantic-model
¶
Bases: BaseModel
Valid SLURM/sudo profile.
| ATTRIBUTE | DESCRIPTION |
|---|---|
name |
Profile name.
TYPE:
|
resource_type |
Type of the corresponding resource.
TYPE:
|
username |
SLURM user to impersonate (e.g. as in
TYPE:
|
Fields:
-
name(NonEmptyStr) -
resource_type(ResourceType) -
username(NonEmptyStr) -
ssh_key_path(None) -
jobs_remote_dir(None) -
tasks_remote_dir(None) -
pixi_cache_dir(None)
Source code in fractal_server/app/schemas/v2/profile.py
Functions:¶
cast_serialize_profile(_data)
¶
Cast/serialize round-trip for Profile data.
We use @validate_call because ProfileCreate is a Union type and it
cannot be instantiated directly.
Return
Serialized version of a valid profile object.