objective categorical abstract machine language personal data server
65
fork

Configure Feed

Select the types of activity you want to include in your feed.

Misc tweaks

futurGH 747d6cb0 62f5240a

+13 -11
+3 -3
Dockerfile
··· 4 4 ARG OPAM_VERSION=2.5.0 5 5 ARG DUNE_VERSION=3.20.2 6 6 7 - RUN sudo apt-get install -y cmake git libev-dev libffi-dev libgmp-dev libssl-dev libsqlite3-dev pkg-config 7 + RUN sudo apt-get install -y cmake git libev-dev libffi-dev libgmp-dev libssl-dev libsqlite3-dev libpcre3-dev pkg-config 8 8 9 9 WORKDIR /home/opam/pegasus 10 10 ··· 26 26 RUN opam exec dune pkg lock 27 27 RUN bash -c "source $NVM_DIR/nvm.sh && opam exec dune build -- --release --stop-on-first-error" 28 28 29 - FROM --platform=linux/amd64 ocaml/opam:debian-12-ocaml-5.2 AS run 29 + FROM --platform=linux/amd64 debian:12 AS run 30 30 31 - RUN sudo apt-get install -y libev-dev 31 + RUN apt-get update && apt-get install -y libev-dev libffi-dev libgmp-dev libssl-dev libsqlite3-dev libpcre3-dev pkg-config 32 32 33 33 COPY --from=build /home/opam/pegasus/_build/default/bin/main.exe /bin/pegasus 34 34
-1
bin/main.ml
··· 241 241 migrate-blobs <did> migrate blobs for a specific user to S3 242 242 |} 243 243 244 - (** CLI entry point *) 245 244 let () = 246 245 let args = Array.to_list Sys.argv |> List.tl in 247 246 match args with
+1 -1
frontend/src/templates/LoginPage.mlx
··· 33 33 </Button> 34 34 </form> 35 35 <span className="text-sm text-mist-100"> 36 - (string "Or ") 36 + (string "or ") 37 37 <a 38 38 href="/account/signup" 39 39 className="text-mana-100 underline hover:text-mana-200">
+3 -3
frontend/src/templates/SignupPage.mlx
··· 17 17 (string "sign up") 18 18 </h1> 19 19 <span className="w-full text-balance text-mist-100"> 20 - (string "Create your account on this PDS.") 20 + (string "You'll need an invite code to create an account on this PDS.") 21 21 </span> 22 22 <form className="w-full flex flex-col mt-4 mb-2 gap-y-2"> 23 23 <input type_="hidden" name="dream.csrf" value=csrf_token /> ··· 44 44 </Button> 45 45 </form> 46 46 <span className="text-sm text-mist-100"> 47 - (string "Already have an account? ") 47 + (string "already have an account? ") 48 48 <a 49 49 href="/account/login" 50 50 className="text-mana-100 underline hover:text-mana-200"> 51 - (string "Sign in") 51 + (string "sign in") 52 52 </a> 53 53 (string ".") 54 54 </span>
+1 -1
pegasus/lib/api/root.ml
··· 29 29 ⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠈⠻⠿⠆⠀⠀⠀⠀⠀⠀ 30 30 31 31 this is [pegasus](https://tangled.org/@futur.blue/pegasus) 32 - it's going to be an atproto personal data server eventually 32 + manage your account at /account 33 33 |} )
+5 -2
pegasus/lib/auth.ml
··· 319 319 @@ Errors.auth_required ~name:"AccountDeactivated" 320 320 "account is deactivated" 321 321 | None -> 322 - Lwt.return_error @@ Errors.auth_required "invalid session" ) 322 + let%lwt () = Session.Raw.clear_session req in 323 + Lwt.return_error @@ Errors.auth_required "no active session" ) 323 324 | None -> 324 325 Lwt.return_error @@ Errors.auth_required "no active session" 325 326 ··· 365 366 "unexpected authorization type" ) 366 367 367 368 let any : verifier = 368 - fun ctx -> try authorization ctx with _ -> unauthenticated ctx 369 + fun ctx -> 370 + try%lwt Lwt_result.map_error raise @@ authorization ctx 371 + with _ -> unauthenticated ctx 369 372 370 373 type t = 371 374 | Unauthenticated