Commit Graph

128 Commits

Author SHA1 Message Date
Harvey Tindall
cacd992aad jf_activity: remove debug line
also bump mediabrowser again to do the same.
2025-12-20 11:49:55 +00:00
Harvey Tindall
23ad016476 mediabrowser: bump to v0.3.34
forgot to switch back from my local copy in the previous commit.
2025-12-20 11:41:35 +00:00
Harvey Tindall
c21df253a1 jf-activity: initial changes
functionality mostly there but needs a UI.
2025-12-16 18:15:39 +00:00
Harvey Tindall
1c755306f9 tray: fix broken dependency. 2025-12-10 17:43:00 +00:00
Harvey Tindall
420a22970d goreleaser: unset GOOS/GOARCH for precompile step
these should be run natively.
2025-12-10 15:05:30 +00:00
Harvey Tindall
d4109c8cf5 matrix: use goolm over libolm, ci: user smaller docker image base
removes one dependency. jfa-go-build-docker has been updated to reflect
this, and in general with a newer debian version and properly included
goreleaser, and a build for amd64. Dockerfiles now use a
"distroless"-style container as their base. Was gonna use
chainguard/glibc-dynamic, but it running as a different user meant it
wouldn't read/write from your /data mount without manual intervention.
2025-12-10 13:25:21 +00:00
Harvey Tindall
b59cd73e43 messages: switch to new template package
rewrote and put in its own repo. Now supports {if a ==/!= b}, string
literals ({if a == "b"}), else/else if and nested if statements.
2025-12-04 11:50:14 +00:00
Harvey Tindall
a4b94b4f45 tray: switch to fork, use higher res icon
switched to a fork of a fork of getlantern/systray which has no
ayatana-appindicator dependency.
2025-12-02 13:05:06 +00:00
Harvey Tindall
320e9cd9d0 mediabrowser: bump
imrpvoed UserNotFound error classification, no longer vulnerable to
random 404s from proxies or whatever (for Jellyfin only, not emby)
2025-12-01 12:43:40 +00:00
Harvey Tindall
836974e1b2 scripts: stop using gopkg.in/yaml
used a different library in scripts/yaml, forgot to in scripts/ini and
main.go
2025-11-27 20:38:16 +00:00
Harvey Tindall
b1c578ccf4 mediabrowser: bump
also updated everything else.
2025-11-23 20:10:34 +00:00
Harvey Tindall
a92f449e7f go: update deps; mediabrowser thread-safe cache
did a go get -u, and updated mediabrowser for a thread-safe user cache,
for #415.
2025-07-16 21:23:06 +01:00
Harvey Tindall
688e941d64 router: implement ETags/If-None-Match based on build time
Essentially caching based on when the program was built.
2025-05-27 16:29:58 +01:00
Harvey Tindall
30acc4f9b8 profiles: fix "max parental rating" nil-value
fixed in v0.3.28 of mediabrowser.
2025-05-27 15:14:15 +01:00
Harvey Tindall
1dfe13951f activities: fix slow load w/ lots of users
Added ID/Name indexing to mediabrowser, and cleaned it up a little bit.
Was taking ~2s with 5000 users and firing tons of requests at Jellyfin,
now take ~160ms from cold boot, ~1ms with cache.
2025-05-26 21:52:31 +01:00
Harvey Tindall
dec5197bfd usercache: we'll do it ourselves
we don't need expr or anything like that, cmp.Less and vim macros exist.
2025-05-26 21:52:31 +01:00
Harvey Tindall
ebff016b5d accounts: add "record count", start searchable user cache
RecordCounter class created from that in activityList, and put in
accountsList. PageCount-type route standardized and made for /users
(/users/count). Created userCache, which regularly generates the
respUser list returned by /users. Added a currently dumb POST /users for
searching/pagination, GET /users is now just for getting -all- users.
go-getted expr, an expression language that seems like it'll be useful
for evaluating local searches. We don't store this data in the badger
    DB, so we can't use the nice query form provided by badgerhold.
2025-05-26 21:52:31 +01:00
Harvey Tindall
01a75c3e23 settings: add jellyseerr wiki link, clarify API key src
An API key is shown in Jellyseerr's setup which is actually for
Jellyfin. I (and I imagine other users have) copied it expecting it was
for Jellyseerr and was surprised the app didn't work. It's now clarified
    in the API Key setting description to get it from the first tab in
    Jellyseerr, and not the "Jellyfin" tab.
2025-05-15 16:14:15 +01:00
Harvey Tindall
4cc5fd7189 mediabrowser: bump for parental rating setting
fixes #382.
2025-05-15 15:38:35 +01:00
Harvey Tindall
d6f5c91d78 backups: add more info, keep 1 of each version opt
backup's filename format has changed, and includes the commit too now. a
Backup struct for going to/from the filename has been added, and the
option "keep 1 backup from each version" has been added, leaving the
most recent backup from each version always. All pre-this-commit backups
are considered the same "old" version.
2025-05-13 15:07:55 +01:00
Harvey Tindall
0ccc314833 go: update deps
including mediabrowser, to add new field in Configuration.
2024-11-05 23:49:20 +00:00
Harvey Tindall
4b564d7f4a bump mediabrowser again, log authed account name 2024-09-04 20:03:09 +01:00
Harvey Tindall
e623897fc1 bump mediabrowser again 2024-09-04 16:01:52 +01:00
Harvey Tindall
ee05f4fc19 bump mediabrowser again 2024-08-29 16:23:44 +01:00
Harvey Tindall
f4a7238110 bump mediabrowser version, always verbose
always enable jf.Verbose, because it really should be.
2024-08-29 14:30:16 +01:00
Harvey Tindall
a4c60c71ea update go.mods
tried to lower required version, most subpackages worked, however some
other dependency means the main package requires 1.22.
2024-08-26 17:26:04 +01:00
Harvey Tindall
86c7551ff8 proxy: use wherever http.Client is, update mautrix
Added a new common.ConfigurableTransport interface which mediabrowser,
ombi, jellyseer, discord, telegram and matrix (i.e.
ThirdPartService/ContactMethodLinker) now all implement. proxies are
bound to them in main.go, Email is still a special case (but from the
previous commit, mailgun does use the proxy).

mautrix/go has been updated, and context.TODO()s stuck everywhere since
I still don't really comprehend why I should use them (FIXME literally).
2024-08-09 21:42:16 +01:00
Harvey Tindall
2310130e6b api clients: return data, error, no status
jellyseerr already did this, but it's been standardised a little more.

Mediabrowser uses it's own genericErr function and error types due to
being a separate package, while jellyseerr and ombi now share errors
defined in common/.
2024-08-06 14:48:31 +01:00
Harvey Tindall
3c3297c8e7 userpage: bump mediabrowser version
so that usernames are compared un-case-sensitively in UserByName. For #354.
2024-08-05 12:37:42 +01:00
Harvey Tindall
05d473dc97 mediabrowser: bump version for JF 10.9.8
Adds missing field(s). For #349.
2024-07-28 13:41:48 +01:00
Harvey Tindall
5702e8012c proxy: use for updater & SMTP
imports a new package to create a HTTP proxy dialer for the SMTP client.
2023-10-05 12:32:25 +01:00
Harvey Tindall
523902f951 proxy: add http/socks5 support, use for Jellyfin
can be found in advanced. Currently only used for the main Jellyfin
client.
2023-10-05 11:25:58 +01:00
Harvey Tindall
f6fdd41b35 jellyfin: retry initial connection (configurable)
retries initial connection to Jellyfin 6 times, with a 10s gap between,
before failing. SHould help with issues of jfa-go starting before
Jellyfin.
Configurable in Settings > Advanced > "Initial auth retry count/gap".
2023-10-03 09:33:56 +01:00
Harvey Tindall
e1292a0780 build: dont install swag if already present 2023-06-27 07:23:25 +01:00
Harvey Tindall
b17d8424e9 profiles: fix application
moving to a DB meant empty slices in the Configuration & Policy structs
were being stored as null, and striking a nerve with Jellyfin.
Mediabrowser library change fixed that by de-nulling them itself, and a
new bool field called "Homescreen" is now used to decide if a profile
has a homescreen layout stored or not. This field is hopefully correctly
filled in during migration.
2023-06-26 13:01:17 +01:00
Harvey Tindall
833be688ac storage: start db migration (badger(hold))
migrating to badger, with the badgerhold frontend. So far, done:
* Announcements (small, for a quick test)
* Discord/Telegram/Matrix/Email

most interaction with badgerhold is done through the standard
Get<x>/Get<x>Key/Set<x>Key/Delete<x>Key. UserExists functions have been
added for email and matrix, and those and the original ones now use a
query against the database rather than sifting through every record.
I've tagged these searched fields as "index" for badgerhold, although this
definitely isn't used yet, and i'm not entirely sure if it'll be useful.

migrateToBadger is now in migrations.go, and a temporary config key
"migrated_to_badger" has been added, although it isn't being used yet,
migration is just running every time during development.
2023-06-24 17:05:04 +01:00
Harvey Tindall
48403ce940 discord: proper support for discriminator-less
names with no discriminator are shown as @username, and search works
with the @ too. Also bumped go version to 1.20, since it was stuck on
1.16 and i felt like trying generics (in an ugly way).
2023-06-12 16:32:40 +01:00
Harvey Tindall
73202e1483 crash: render ANSI colors on crash page
Could not for the life of me get any regex to properly strip the ANSI
escape sequences, so the text log will have to suffer with them, but the
ansihtml library is now used to render them into HTML.
2023-06-12 15:48:07 +01:00
Harvey Tindall
2cb72e1f48 module update, add notice to site 2023-06-11 14:22:58 +01:00
Harvey Tindall
0674e04ee1 go module update/tidy 2023-02-20 10:47:54 +00:00
Harvey Tindall
4c3e310634 use go install for swag in goreleaser 2022-03-22 15:16:04 +00:00
Harvey Tindall
15e5564b12 discord: add/move to slash commands
the version of the discord library with support for this isn't
necessarily stable, so normal ! commands will still be available. The
user is no longer DMed for the PIN, instead they type /pin <PIN>.
2022-01-26 21:47:02 +00:00
Harvey Tindall
e66241ddcb fix crash page css when using goreleaser 2022-01-26 15:45:21 +00:00
Harvey Tindall
be1d081629 build: fix css bundling bug with new esbuild
local testing was being done with an older version of esbuild which
didn't mind @tailwind statements before @imports (it complained, but did
its job). On the latest version used in Docker builds, it would leave
the @import statements intact which broke things like modals.
2022-01-26 14:26:10 +00:00
Harvey Tindall
d9f8785372 form: add CAPTCHAs
Enabled in Settings > Captchas, shows a captcha on the account creation
form.
2022-01-10 01:55:48 +00:00
Harvey Tindall
77c05a4d4f prefix css with version to avoid cache conflict 2022-01-08 16:42:36 +00:00
Harvey Tindall
9874dce520 merge tailwind and upgraded a17t
a17t v0.10 became a tailwind plugin rather than standalone css, and made
some other changes. Much of the original custom CSS now uses tailwind
classes, and there have been some other UI changes.
2022-01-04 20:28:36 +00:00
Harvey Tindall
360c25d084 accounts: hide "Send PWR" when link resets disabled
for #182.
2021-12-24 19:05:48 +00:00
Harvey Tindall
d47afe05f4 update deps, fix connection error log 2021-12-22 23:11:00 +00:00
Harvey Tindall
9092f42834 remove vulnerable node deps, cleanup 2021-11-14 14:50:40 +00:00