Compare commits
15 Commits
feat/local
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| 9490a06303 | |||
| 5fb1ae0678 | |||
| 97c03e216b | |||
|
|
bab4490847 | ||
|
8e824d4afa
|
|||
|
|
777cf1a31d | ||
|
efacb2a332
|
|||
|
|
17c4e9dd22 | ||
| 503ccbb2ad | |||
|
54c40d7acc
|
|||
|
d8d5e076ba
|
|||
|
|
fd2b3fe691 | ||
| 6ae7a7dac8 | |||
|
e429a855e5
|
|||
|
|
9ed60b7cc8 |
@@ -1,5 +1,41 @@
|
||||
# Changelog
|
||||
|
||||
## [1.40.5](https://gitlab.com/oceanbox/Poseidon/compare/v1.40.4...v1.40.5) (2026-01-21)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **xtractor:** Reduce to 4 cores per task ([8e824d4](https://gitlab.com/oceanbox/Poseidon/commit/8e824d4afa0b03f59e006d3a0d50fb216e71483e))
|
||||
|
||||
## [1.40.4](https://gitlab.com/oceanbox/Poseidon/compare/v1.40.3...v1.40.4) (2026-01-21)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **xtractor:** Reduce core requirement to 8 ([efacb2a](https://gitlab.com/oceanbox/Poseidon/commit/efacb2a3322de0ced45db4eec240846f4e371a75))
|
||||
|
||||
## [1.40.3](https://gitlab.com/oceanbox/Poseidon/compare/v1.40.2...v1.40.3) (2026-01-20)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **inbox|xtracto:** Delete/Read msg and allow non-ascii xtractor names ([d8d5e07](https://gitlab.com/oceanbox/Poseidon/commit/d8d5e076baf8b559200f2da91237f9874678b216))
|
||||
* **multiauth:** Add clientId to redirect on signout ([54c40d7](https://gitlab.com/oceanbox/Poseidon/commit/54c40d7accc4bbc43f66dda0df647ccac482a2b0))
|
||||
|
||||
## [1.40.2](https://gitlab.com/oceanbox/Poseidon/compare/v1.40.1...v1.40.2) (2026-01-19)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **xtract:** Disabled if not allowed to simulate transport ([e429a85](https://gitlab.com/oceanbox/Poseidon/commit/e429a855e5bd00493e2f99647092aebce9c99a2a))
|
||||
|
||||
## [1.40.1](https://gitlab.com/oceanbox/Poseidon/compare/v1.40.0...v1.40.1) (2026-01-19)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* fix tilt build on net10 ([d5cde19](https://gitlab.com/oceanbox/Poseidon/commit/d5cde19250847f7b091cfa5f65eb703405c202b6))
|
||||
|
||||
# [1.40.0](https://gitlab.com/oceanbox/Poseidon/compare/v1.39.2...v1.40.0) (2026-01-16)
|
||||
|
||||
|
||||
|
||||
@@ -28,8 +28,8 @@
|
||||
"nixpkgs": {
|
||||
"type": "Channel",
|
||||
"name": "nixpkgs-unstable",
|
||||
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.05pre927565.13868c071cc7/nixexprs.tar.xz",
|
||||
"hash": "sha256-wufp5c0nWh/87f9eK7xy1eZXms5zd4yl6S4SR+LfA08="
|
||||
"url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.05pre930822.ed142ab1b3a0/nixexprs.tar.xz",
|
||||
"hash": "sha256-XH6awru9NnBc/m+2YhRNT8r1PAKEiPGF3gs//F3ods0="
|
||||
},
|
||||
"pre-commit": {
|
||||
"type": "Git",
|
||||
@@ -40,9 +40,9 @@
|
||||
},
|
||||
"branch": "master",
|
||||
"submodules": false,
|
||||
"revision": "f0927703b7b1c8d97511c4116eb9b4ec6645a0fa",
|
||||
"url": "https://github.com/cachix/git-hooks.nix/archive/f0927703b7b1c8d97511c4116eb9b4ec6645a0fa.tar.gz",
|
||||
"hash": "sha256-6MkqajPICgugsuZ92OMoQcgSHnD6sJHwk8AxvMcIgTE="
|
||||
"revision": "a1ef738813b15cf8ec759bdff5761b027e3e1d23",
|
||||
"url": "https://github.com/cachix/git-hooks.nix/archive/a1ef738813b15cf8ec759bdff5761b027e3e1d23.tar.gz",
|
||||
"hash": "sha256-Efs3VUPelRduf3PpfPP2ovEB4CXT7vHf8W+xc49RL/U="
|
||||
}
|
||||
},
|
||||
"version": 7
|
||||
|
||||
@@ -24,7 +24,7 @@ pkgs.mkShellNoCC {
|
||||
|
||||
# JavaScript
|
||||
pkgs.bun
|
||||
pkgs.nodejs
|
||||
pkgs.nodejs_25
|
||||
|
||||
# Devlopment tools
|
||||
pkgs.npins
|
||||
|
||||
@@ -14,7 +14,7 @@ pack_path := "../../packages"
|
||||
|
||||
vite_prod := "bunx --bun vite build -c ../../vite.config.js -m production --emptyOutDir --outDir " + "../../dist/public"
|
||||
vite_dev := "bunx --bun vite build -c ../../vite.config.js -m development --minify false --sourcemap true --emptyOutDir --outDir " + "../../dist/public"
|
||||
vite := "bunx --bun vite -c ../../vite.config.js -m development "
|
||||
vite := "bunx vite -c ../../vite.config.js -m development "
|
||||
|
||||
# Default recipe - show available commands
|
||||
default:
|
||||
|
||||
@@ -43,16 +43,16 @@ let inboxDialog
|
||||
let table = document.getElementById "inbox-table"
|
||||
async {
|
||||
let! mbox = Remoting.inboxApi().getMessages ()
|
||||
// if mbox.Length = 0 then
|
||||
// table?items <- [| {
|
||||
// id = Guid.Empty
|
||||
// content = ""
|
||||
// unread = false
|
||||
// type' = MessageType.Note
|
||||
// created = DateTime.Now
|
||||
// } |]
|
||||
// else
|
||||
table?items <- mbox
|
||||
if mbox.Length = 0 then
|
||||
table?items <- [| {
|
||||
id = Guid.Empty
|
||||
content = ""
|
||||
unread = false
|
||||
type' = MessageType.Note
|
||||
created = DateTime.Now
|
||||
} |]
|
||||
else
|
||||
table?items <- mbox
|
||||
} |> Async.StartImmediate
|
||||
|
||||
Hook.useEffectOnChange(arg.unread, loadMessages)
|
||||
@@ -65,30 +65,18 @@ let inboxDialog
|
||||
|> Set.ofSeq
|
||||
|> setSelected
|
||||
|
||||
let doDelete _ =
|
||||
let doDelete selected _ =
|
||||
let table = document.getElementById "inbox-table"
|
||||
let selectedSet : Guid JS.Set = table?selectedSet
|
||||
let items: InboxItem array = table?items
|
||||
async {
|
||||
let toDelete =
|
||||
items
|
||||
|> Array.filter (fun item -> selectedSet.has(item.id))
|
||||
|> Array.map (fun item -> item.id)
|
||||
|
||||
console.debug("Deleting", toDelete.Length, "messages")
|
||||
items
|
||||
|> Array.filter (fun item -> Set.contains item.id selected)
|
||||
|> Array.iter (fun item ->
|
||||
console.log("Delete: %A", item.content)
|
||||
do arg.deleteMessage item.id
|
||||
)
|
||||
|
||||
for id in toDelete do
|
||||
arg.deleteMessage id
|
||||
|
||||
// Clear selection immediately
|
||||
selectedSet.clear()
|
||||
setSelected Set.empty
|
||||
|
||||
// Wait a bit for server to process, then reload
|
||||
do! Async.Sleep 200
|
||||
let! mbox = Remoting.inboxApi().getMessages ()
|
||||
table?items <- mbox
|
||||
} |> Async.StartImmediate
|
||||
loadMessages ()
|
||||
|
||||
let doRead selected _ =
|
||||
let table = document.getElementById "inbox-table"
|
||||
@@ -118,7 +106,7 @@ let inboxDialog
|
||||
html $"""
|
||||
<sp-field-group horizontal>
|
||||
<sp-action-button
|
||||
@click={Ev(doDelete)}
|
||||
@click={Ev(doDelete selected)}
|
||||
?disabled={selected.Count = 0}>
|
||||
<sp-icon-delete slot="icon"></sp-icon-delete> Delete selected
|
||||
</sp-action-button>
|
||||
@@ -308,11 +296,8 @@ let inboxDialog
|
||||
let sortFn = if sortDir = "asc" then Array.sortBy else Array.sortByDescending
|
||||
table?items
|
||||
|> sortFn (fun item -> JS.expr_js $"{item}[{sortKey}]")
|
||||
|> fun items -> table?items <- items))
|
||||
|
||||
let table =
|
||||
html $"""
|
||||
"""
|
||||
|> fun items -> table?items <- items)
|
||||
)
|
||||
|
||||
html $"""
|
||||
<div class="inbox-dialog">
|
||||
|
||||
@@ -100,7 +100,7 @@ let private simAccordion (dispatch: Msg -> unit) model =
|
||||
console.debug $"policies: %A{model.simPolicies}"
|
||||
let disabled = model.archive.id = Guid.Empty
|
||||
|
||||
// TODO(mrtz): Create custom policy for plumes, for now just inherit from drifters.
|
||||
// TODO(mrtz): Create custom policy for plume and xtract, for now just inherit from drifters.
|
||||
let disabledPlume =
|
||||
model.simPolicies |> Array.contains (DriftersPolicy.SubmitTransport false)
|
||||
let disabledXtract =
|
||||
@@ -189,7 +189,7 @@ let private simAccordion (dispatch: Msg -> unit) model =
|
||||
<sp-action-button
|
||||
static="primary"
|
||||
style="flex-grow: 1"
|
||||
?disabled={disabled}
|
||||
?disabled={disabledXtract }
|
||||
@click={Ev (chooseMode (DataExtraction DefaultXtract))}
|
||||
>
|
||||
Extract Data
|
||||
|
||||
@@ -84,7 +84,7 @@ type XtractActor(host: ActorHost, slurm: SlurmClient, settings: Common.Settings,
|
||||
let grp = if g.Length > 0 then g[0] else ""
|
||||
let dep = None
|
||||
let part = partition |> Option.defaultValue "short"
|
||||
let cpt = 16
|
||||
let cpt = 4
|
||||
|
||||
taskResult {
|
||||
let! archiveName =
|
||||
|
||||
@@ -101,20 +101,20 @@ type IPrincipalActor =
|
||||
inherit IActor
|
||||
abstract IsActive: unit: unit -> Task<bool>
|
||||
abstract IsRegistered: unit: unit -> Task<bool>
|
||||
abstract GetGroups: unit: unit -> Task<string[]>
|
||||
abstract GetRoles: unit: unit -> Task<string[]>
|
||||
abstract GetGroups: unit: unit -> Task<string array>
|
||||
abstract GetRoles: unit: unit -> Task<string array>
|
||||
abstract Register: unit: unit -> Task<bool>
|
||||
abstract Activate: unit: unit -> Task<bool>
|
||||
abstract Disable: unit: unit -> Task<bool>
|
||||
|
||||
type UserCredentials = { username: string; password: string }
|
||||
|
||||
// needed by signalr
|
||||
// NOTE: Needed by signalr
|
||||
type UserIdProvider() =
|
||||
interface IUserIdProvider with
|
||||
member this.GetUserId(ctx: HubConnectionContext) =
|
||||
let uid = ctx.User.Identity.Name
|
||||
Log.Verbose $"UserIdProvider: {uid}"
|
||||
Log.Verbose $"UserIdProvider: %s{uid}"
|
||||
uid
|
||||
|
||||
[<RequireQualifiedAccess>]
|
||||
@@ -130,6 +130,7 @@ let tryStr str =
|
||||
None
|
||||
else
|
||||
Some str
|
||||
|
||||
let tryGetEnv =
|
||||
Environment.GetEnvironmentVariable
|
||||
>> tryStr
|
||||
@@ -140,7 +141,7 @@ let authorize: HttpHandler =
|
||||
|
||||
let addGroupsAndRoles (principal: ClaimsPrincipal) : Async<bool> =
|
||||
let addToIdentity (identity: ClaimsIdentity) ctype cc =
|
||||
eprintfn $"[MultiAuth] Adding claim {ctype} to principal: %A{cc}"
|
||||
eprintfn $"[MultiAuth] Adding claim %s{ctype} to principal: %A{cc}"
|
||||
cc
|
||||
|> Array.choose (fun g ->
|
||||
if not (principal.HasClaim (fun claim -> claim.Type = ctype && claim.Value = g)) then
|
||||
@@ -295,14 +296,18 @@ let oidOptions (settings: MultiAuthSettings) (o: OpenIdConnectOptions) =
|
||||
fun e ->
|
||||
task {
|
||||
eprintfn "[MultiAuth] RedirectToIdentityProvider: %A" e.Request.Host.Value
|
||||
// hack for https behind proxy
|
||||
e.ProtocolMessage.ClientId <- settings.oidc.clientId
|
||||
// HACK: For https behind proxy
|
||||
e.ProtocolMessage.RedirectUri <- $"https://{e.Request.Host.Value}/signin-oidc"
|
||||
return ()
|
||||
}
|
||||
o.Events.OnRedirectToIdentityProviderForSignOut <-
|
||||
fun e ->
|
||||
task {
|
||||
// hack for https behind proxy
|
||||
eprintfn "[MultiAuth] OnRedirectToIdentityProviderForSignOut: %A" e.Request.Host.Value
|
||||
// HACK: Avoid saving tokens
|
||||
e.ProtocolMessage.ClientId <- settings.oidc.clientId
|
||||
// HACK: For https behind proxy
|
||||
e.ProtocolMessage.PostLogoutRedirectUri <- $"https://{e.Request.Host.Value}/signout-callback-oidc"
|
||||
return ()
|
||||
}
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<OutputType>Library</OutputType>
|
||||
<TargetFramework>net10.0</TargetFramework>
|
||||
<PackageId>Oceanbox.ServerPack</PackageId>
|
||||
<Version>1.40.0</Version>
|
||||
<Version>1.40.5</Version>
|
||||
<RestorePackagesWithLockFile>true</RestorePackagesWithLockFile>
|
||||
<GenerateDocumentationFile>true</GenerateDocumentationFile>
|
||||
<IsPackable>true</IsPackable>
|
||||
|
||||
@@ -251,7 +251,7 @@ module Xtract =
|
||||
Log.Debug $"Sorcerer.Xtract.downloadZip: user={username}, archiveId={archiveId}, jobId={jobId}"
|
||||
let fileName = $"/data/archives/xtract/{username}/{jobId}/xtract.zip"
|
||||
if File.Exists fileName then
|
||||
(setHttpHeader "Content-Disposition" $"attachment; filename={outname}.zip" >=> streamFile true fileName None None) next ctx
|
||||
(setHttpHeader "Content-Disposition" $"attachment; filename=site-report.zip" >=> streamFile true fileName None None) next ctx
|
||||
else
|
||||
Log.Warning $"Xtract file not found: {fileName}"
|
||||
RequestErrors.NOT_FOUND "File not found" next ctx
|
||||
|
||||
Reference in New Issue
Block a user