@apocaliss92/addon-series-scraper 0.0.0-stage → 0.1.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +174 -0
- package/README.md +134 -2
- package/assets/icon.svg +22 -0
- package/dist/_stub.js +11345 -0
- package/dist/_virtual_mf-localSharedImportMap___mfe_internal__addon_series_scraper_page__mf_owner__1-C2oznnyl.js +82 -0
- package/dist/addon.js +377 -0
- package/dist/dist-CXrbtx5R.js +19 -0
- package/dist/docker-import-C1Os3QjE.js +316 -0
- package/dist/embedded.js +925 -0
- package/dist/esm-BaRSigns.js +1331 -0
- package/dist/extract-zip-cgdW-jDq.js +1346 -0
- package/dist/helpers-BBnuD0Mu.js +5 -0
- package/dist/helpers-CpKI7ps_.js +9 -0
- package/dist/hostInit-D1MnMgTc.js +177 -0
- package/dist/index.js +3 -0
- package/dist/pendingShares-CffjjPWP.js +38 -0
- package/dist/proxy-Btrb1iBN.js +233455 -0
- package/dist/pump-DDROyUu9.js +161 -0
- package/dist/remoteEntry.js +783 -0
- package/dist/rolldown-runtime-cIwnrN2i.js +46 -0
- package/dist/state-store-DT6l2jtx.js +420 -0
- package/dist/tar-fs-ZoqVwI4a.js +2673 -0
- package/dist/utils-CHYfMMdo.js +2951 -0
- package/dist/yargs-CBdcwHg0.js +2867 -0
- package/i18n/en.json +43 -0
- package/i18n/it.json +43 -0
- package/package.json +107 -4
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## [Unreleased]
|
|
4
|
+
|
|
5
|
+
## [0.1.21] - 2026-12-02
|
|
6
|
+
|
|
7
|
+
### Changed
|
|
8
|
+
|
|
9
|
+
- The addon is published as @apocaliss92/addon-series-scraper; @dominevo/addon-series-scraper is no longer updated. Requires Dominevo server 0.1.43 or later.
|
|
10
|
+
|
|
11
|
+
## [0.1.20] - 2026-12-02
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
|
|
15
|
+
- Built on the core now published as @apocaliss92/series-scraper-core; the source moved to github.com/apocaliss92/addon-series-scraper. No behaviour change (planning#868)
|
|
16
|
+
|
|
17
|
+
## [0.1.19] - 2026-12-02
|
|
18
|
+
|
|
19
|
+
### Fixed
|
|
20
|
+
|
|
21
|
+
- Old Chrome profiles and Chrome home are moved out of the backed-up data folder when the addon starts, not at the next Chrome launch, so the next system backup no longer fails on them (planning#867)
|
|
22
|
+
|
|
23
|
+
## [0.1.18] - 2026-12-02
|
|
24
|
+
|
|
25
|
+
### Fixed
|
|
26
|
+
|
|
27
|
+
- Chrome profiles and Chrome's home now live in the node cache, outside the system backup: a Chrome SQLite file left behind no longer makes the nightly backup fail (planning#867)
|
|
28
|
+
- An addon restart no longer sends a "VPN gate opened" notification: "opened" follows only a reported "closed", and a gate still closed 2 minutes after start is reported (planning#864)
|
|
29
|
+
|
|
30
|
+
## [0.1.17] - 2026-12-02
|
|
31
|
+
|
|
32
|
+
### Fixed
|
|
33
|
+
|
|
34
|
+
- YouTube downloads prefer H.264 over AV1: the format picked first was often AV1, which many Plex clients cannot play without transcoding; AV1 or VP9 is used only when no H.264 fits the height cap (planning#864)
|
|
35
|
+
|
|
36
|
+
## [0.1.16] - 2026-12-02
|
|
37
|
+
|
|
38
|
+
### Added
|
|
39
|
+
|
|
40
|
+
- A YouTube tab next to the series and movies search: search by text or by channel, download a video with its thumbnail and the channel's subtitles, and follow each download's state; yt-dlp is a pinned binary that updates itself weekly and falls back to the pin, and its network exit is chosen in the settings (home connection by default) (planning#864)
|
|
41
|
+
- YouTube settings: a switch (off by default: until it is on, the YouTube tab says to enable it and the API refuses), a videos library folder, and a Plex videos section. With a folder set, a finished video lands in `<folder>/<Channel>/<date> - <Title> [<id>].mp4` beside its thumbnail, a Kodi/Plex `.nfo` and the channel's own subtitles, and only after ffmpeg confirmed it is a playable video; the channel folder is then scanned in the Plex videos section (planning#864)
|
|
42
|
+
- The addon declares `series-scraper/video-started`, `video-completed` and `video-failed` (payload `channel`, `title`, and `error` on a failure), so a notification rule can be written on YouTube downloads. With the egress firewall on and no exit chosen for YouTube, a search or download is refused at once with a message to choose one, instead of timing out (planning#864)
|
|
43
|
+
|
|
44
|
+
## [0.1.15] - 2026-12-02
|
|
45
|
+
|
|
46
|
+
### Fixed
|
|
47
|
+
|
|
48
|
+
- A download interrupted by an addon restart is no longer moved into the library as a truncated file: an HLS download that stopped before 97% of its length fails and is retried, and every file is checked for a readable video stream and duration before it is placed (planning#849)
|
|
49
|
+
|
|
50
|
+
## [0.1.14] - 2026-12-01
|
|
51
|
+
|
|
52
|
+
### Fixed
|
|
53
|
+
|
|
54
|
+
- Episodes and movies placed in a library are now writable by the media managers (folders the scraper creates 0777, files 0666, like Unraid's New Permissions), so Sonarr can rename and move them; on by default, turned off with `libraryOpenPermissions` (modes `libraryDirMode` / `libraryFileMode`). Season folders follow Sonarr's own season folder format ("Season 5" rather than "Season 05") when Sonarr is configured (planning#849)
|
|
55
|
+
|
|
56
|
+
## [0.1.13] - 2026-12-01
|
|
57
|
+
|
|
58
|
+
### Added
|
|
59
|
+
|
|
60
|
+
- The addon now declares its own event kinds (`series-scraper/episode-started`, `episode-completed`, `episode-failed`, `captcha-required`, `vpn-gate-closed`, `vpn-gate-opened`), so a notification rule can be written on them. They are emitted in embedded mode whatever the "Notify through" setting is; leave that empty once a rule is used, to avoid a double notification. The VPN gate events fire once per change, not on every check. Requires server 0.1.36 (planning#849)
|
|
61
|
+
|
|
62
|
+
## [0.1.12] - 2026-12-01
|
|
63
|
+
|
|
64
|
+
### Added
|
|
65
|
+
|
|
66
|
+
- Embedded mode now also pushes the start of each episode (`episode_start`), as the old webhook did, to the notification target. Scan and download starts are still not pushed (planning#849)
|
|
67
|
+
- Scraper settings: a Plex scan delay field, and a "Remove the stored key" switch for the Sonarr and Radarr keys and the Plex token (planning#849)
|
|
68
|
+
|
|
69
|
+
### Fixed
|
|
70
|
+
|
|
71
|
+
- On first start after this update, credentials an older version left in plain text in the saved state (the Sonarr and Radarr keys, the Plex token, webhook and site headers) are moved into the keychain and removed from the state; the move is logged as counts only. Downgrading below this version loses the site cookies and webhook headers (the older code does not read them from the keychain) (planning#849)
|
|
72
|
+
- Webhook addresses: the host part is shown and editable, the path and query (where a token usually sits) are never shown and are kept when only the host changes; typing a full address replaces both (planning#849)
|
|
73
|
+
- A plugin setting whose name reads like a credential (token, key, secret, password and so on) is no longer shown: it appears empty, and leaving it empty on save keeps the stored value (planning#849)
|
|
74
|
+
- Importing the sites export with "replace" keeps the cookies of sites that come back, and an empty credential header with no stored value is no longer saved as an empty header (planning#849)
|
|
75
|
+
- Settings, webhooks and site headers no longer send a stored secret to the page: the Sonarr and Radarr keys, the Plex token, credential headers of a webhook and cookies or tokens in a site's headers are kept in the keychain and shown only as set or empty, and a plain edit no longer wipes them (planning#849)
|
|
76
|
+
- Site headers are now shown and editable (names and plain values); a credential header shows empty and an empty value keeps the stored one (planning#849)
|
|
77
|
+
- Embedded mode hides the Webhooks section, which never fires there, and points to the "Notify through" setting (planning#849)
|
|
78
|
+
|
|
79
|
+
## [0.1.11] - 2026-12-01
|
|
80
|
+
|
|
81
|
+
### Added
|
|
82
|
+
|
|
83
|
+
- Embedded mode: the captcha exit can use the home connection on purpose (an exit option, offered only on the captcha exit): it is exempt from the VPN leak check, shown as an informational "home" state, and serves hoster link resolution and captcha only; media downloads always go through the VPN and any other request routed to it is refused. Moving the captcha role to another exit clears the choice on the old one (planning#849)
|
|
84
|
+
|
|
85
|
+
## [0.1.10] - 2026-12-01
|
|
86
|
+
|
|
87
|
+
### Fixed
|
|
88
|
+
|
|
89
|
+
- Embedded mode: HLS downloads with a pinned audio language no longer fail with "Could not write header" (a same-language subtitle was mapped into the mp4); only the best video and one audio are kept, and relative download folders land in the addon data directory instead of the container image (planning#849)
|
|
90
|
+
|
|
91
|
+
## [0.1.9] - 2026-12-01
|
|
92
|
+
|
|
93
|
+
### Fixed
|
|
94
|
+
|
|
95
|
+
- Embedded mode: plugins that require cheerio load again; the tunnel binary, media tools and Chrome downloads (pinned by sha256, fixed hosts) work while the VPN gate is closed, so an exit can be built; a failed exit setup now logs its cause (planning#849)
|
|
96
|
+
- Embedded mode: a plugin can no longer reach the network outside the VPN through cheerio (`fromURL` is removed from the module a plugin receives), and the pinned-download allowance lists only the hosts the setup downloads use (planning#849)
|
|
97
|
+
|
|
98
|
+
## [0.1.8] - 2026-12-01
|
|
99
|
+
|
|
100
|
+
### Added
|
|
101
|
+
|
|
102
|
+
- Embedded mode: the scraper's Logs page lists, pages and downloads the addon's lines from Dominevo's own log store (the newest 2000); clearing is refused with a reason, because the store is shared (planning#849)
|
|
103
|
+
- Embedded mode: nothing starts without the VPN. The scraper runs strict and a gate keeps every outbound job and route (503 `waiting-for-vpn`) closed until the default exit is up, tested and leak-checked; a dropped tunnel pauses downloads and the gate reopens by itself. A banner shows the state (planning#849)
|
|
104
|
+
- Embedded mode: the NordVPN server lookup works while the VPN gate is closed (a direct, logged call to api.nordvpn.com only), so the first exit can be created (planning#849)
|
|
105
|
+
- Embedded mode: log lines and their meta are scrubbed of credentials (tokens, cookies, JSON secrets, webhook and bot paths); the NordVPN lookup follows no redirect and reads a capped body (planning#849)
|
|
106
|
+
- Embedded mode: plugins that require cheerio load again; the tunnel binary, media tools and Chrome downloads (pinned by sha256, fixed hosts) work while the VPN gate is closed, so an exit can be built; a failed exit setup now logs its cause (planning#849)
|
|
107
|
+
- README: the full Docker-to-embedded migration, media mounts, permissions, logs and the VPN guarantee (planning#849)
|
|
108
|
+
|
|
109
|
+
## [0.1.7] - 2026-12-01
|
|
110
|
+
|
|
111
|
+
### Added
|
|
112
|
+
|
|
113
|
+
- Settings: "Import from Docker" previews and applies the scraper's Docker data directory (collections, credentials, plugins) copied into the addon's `import` folder, into the embedded store; credentials are shown by name only, and an apply refuses to overwrite existing data unless asked (planning#849)
|
|
114
|
+
|
|
115
|
+
## [0.1.6] - 2026-12-01
|
|
116
|
+
|
|
117
|
+
### Added
|
|
118
|
+
|
|
119
|
+
- Embedded mode (setting "Backend"): the scraper runs inside this addon instead of an external backend. Its state lives in the Dominevo records, its credentials in the keychain, finished downloads can be pushed to a notification target, and ffmpeg, wireproxy and a headless Chrome are fetched on first use. External stays the default and is unchanged; a change of mode applies on the next addon restart (planning#849)
|
|
120
|
+
|
|
121
|
+
### Removed
|
|
122
|
+
|
|
123
|
+
- The unused "Mode" setting (frontend / full-stack): a stored value is ignored. Use "Backend" (external / embedded)
|
|
124
|
+
|
|
125
|
+
## [0.1.5] - 2026-12-01
|
|
126
|
+
|
|
127
|
+
### Added
|
|
128
|
+
|
|
129
|
+
- Cross-site fallback sources: Watch on a merged search card can add the other sites as fallback sources; Watched groups them under their primary with a "+N fallback sites" badge and move up/down/remove; the entry settings show the role and order; Downloads history shows which site delivered each item and every site's outcome (planning#848)
|
|
130
|
+
|
|
131
|
+
## [0.1.4] - 2026-12-01
|
|
132
|
+
|
|
133
|
+
### Changed
|
|
134
|
+
|
|
135
|
+
- A real icon: the scraper's spider pulling up a file, in the addon tile style
|
|
136
|
+
|
|
137
|
+
## [0.1.3] - 2026-12-01
|
|
138
|
+
|
|
139
|
+
### Added
|
|
140
|
+
|
|
141
|
+
- Scraper settings: a Plex section (switch, address, token, series and movies libraries picked from Plex, optional path map, connection test); the scraper then asks Plex to scan just the series or movie folder once when a download job finishes (planning#850)
|
|
142
|
+
|
|
143
|
+
## [0.1.2] - 2026-12-01
|
|
144
|
+
|
|
145
|
+
### Added
|
|
146
|
+
|
|
147
|
+
- Search asks every scraper site at once and groups the results per site, each section with its own loading and error state; a Merge switch unifies the same title across sites into one card listing every site that has it, and the source selector keeps a single-site filter (All sites by default) (planning#848)
|
|
148
|
+
|
|
149
|
+
## [0.1.1] - 2026-12-01
|
|
150
|
+
|
|
151
|
+
### Added
|
|
152
|
+
|
|
153
|
+
- Library and Watched rows show a poster thumbnail when the scraper provides one, and each plugin shows an icon for its kind
|
|
154
|
+
- Watched: each series shows how many seasons are active and how many episodes are on disk, with a scan switch and the episode count per season
|
|
155
|
+
- Watched: an entry's Settings dialog edits its network exit, preferred language and per-season episode range and offset
|
|
156
|
+
|
|
157
|
+
### Fixed
|
|
158
|
+
|
|
159
|
+
- Search: result posters are shown whole instead of cropped, and a result already in Sonarr or Radarr carries an In library / On disk badge
|
|
160
|
+
- Downloads: a series is one row with its aggregate progress and state, and its episodes expand under it
|
|
161
|
+
- Watched: saving a part that follows another updates the list with the base part too, a failed save says the base was already written; an unknown download total shows a dash; the exit badge no longer hides an unreadable exit list
|
|
162
|
+
|
|
163
|
+
## [0.1.0] - 2026-12-01
|
|
164
|
+
|
|
165
|
+
### Added
|
|
166
|
+
|
|
167
|
+
- First version: Watched and Downloads pages, settings view, and an admin-only proxy to the scraper backend (frontend mode).
|
|
168
|
+
- The proxy refuses paths outside the backend `/api`, link-local and unspecified targets, and times out an unreachable backend after 10 s; the backend URL has no default.
|
|
169
|
+
- Search page: pick a source site, search, browse seasons, episodes and links, download a link, add a title to the watch list (Sonarr / Radarr title, preferred language, season mapping), preview a season's episodes from the Watched menu and search another site for an episode.
|
|
170
|
+
- Phone: season preview actions open from the row sheet instead of scrolling sideways, downloads and watched rows show speed, size and source in their sheet, the external search sheet fits its content, and Watch waits for the watch list refresh.
|
|
171
|
+
- Phone: tapping a watched, preview or download row opens a labelled action sheet (Scanning switch, full-width actions, Remove behind its confirm); search results use two columns, seasons, episodes and links are plain lists with real Open buttons and scroll into view, the downloads history loads 20 at a time with Show more, and the settings page keeps its card padding.
|
|
172
|
+
- Library, Sites, Plugins, Books, Logs, VPN and Scraper settings views ported from the scraper's own frontend (captchas excluded). Secrets (VPN keys and passwords, API keys, webhook URLs) are write-only: only whether they are set is shown. Row actions open from a sheet on a phone.
|
|
173
|
+
|
|
174
|
+
- The addon process uses about 40 MB less memory at start.
|
package/README.md
CHANGED
|
@@ -1,3 +1,135 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @apocaliss92/addon-series-scraper
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Dominevo addon (id `series-scraper`, hub-only) that puts the series scraper
|
|
4
|
+
into the admin UI. By default (`backendMode: external`) the scraper's own backend keeps running
|
|
5
|
+
elsewhere and the addon proxies to it; `embedded` runs the scraper core inside the addon (restart to switch).
|
|
6
|
+
|
|
7
|
+
- Settings (`backendMode`, `backendUrl`, the notifier target and three credentials) are cluster-scoped settings of the `app-source` cap, edited on the page's Settings view.
|
|
8
|
+
- `/addon/series-scraper/api/*` proxies to `<backendUrl>/api/*` (admin only; SSE unbuffered, backpressure honoured, upstream aborted when the client closes, 502 JSON when unreachable).
|
|
9
|
+
- `/addon/series-scraper/config` reads and writes the settings (admin only).
|
|
10
|
+
- Page views: Watched, Library, Search, Downloads, Sites, Plugins, Books, Logs, VPN, Scraper settings, Settings (`?view=`). English and Italian.
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
npm install
|
|
14
|
+
npm run build # server bundle + Module Federation page remote
|
|
15
|
+
npm run validate # manifest vs dist
|
|
16
|
+
npm test
|
|
17
|
+
dominevo deploy . # dev hub only
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
Not yet: captchas.
|
|
21
|
+
|
|
22
|
+
## Backend target policy
|
|
23
|
+
|
|
24
|
+
The backend URL is an administrator's setting and is trusted as such: it may be
|
|
25
|
+
loopback or any private LAN address. It is checked when saved and again on every
|
|
26
|
+
proxied request, and these targets are refused (`backend-url-invalid` on save,
|
|
27
|
+
`502 backend-url-refused` at request time):
|
|
28
|
+
|
|
29
|
+
- link-local: `169.254.0.0/16` (including the cloud metadata address) and `fe80::/10`
|
|
30
|
+
- unspecified: `0.0.0.0` and `::`
|
|
31
|
+
- the IPv6 metadata address `fd00:ec2::254`
|
|
32
|
+
|
|
33
|
+
The refusal judges the hostname literal only: a DNS name that resolves to a
|
|
34
|
+
link-local address is not caught.
|
|
35
|
+
|
|
36
|
+
A request path may never leave `<backend>/api/` (`..`, `%2e%2e` and encoded
|
|
37
|
+
variants answer `400 path-outside-api`). The 10 s timeout (`504 backend-timeout`) covers the
|
|
38
|
+
connection only: a backend that accepts and then never answers is held until the
|
|
39
|
+
client leaves, and an open event stream has no idle timeout. With no URL set the proxy answers `503 backend-not-configured`.
|
|
40
|
+
|
|
41
|
+
## Packaging notes
|
|
42
|
+
|
|
43
|
+
Dev dependencies use `^` pins and `tsconfig.json` is standalone (no `paths` into
|
|
44
|
+
sibling packages) because this repository is not an npm workspace of the server
|
|
45
|
+
monorepo, so `*` pins and workspace `paths` would not resolve.
|
|
46
|
+
|
|
47
|
+
## Moving from the Docker container to the embedded scraper
|
|
48
|
+
|
|
49
|
+
### The two modes
|
|
50
|
+
|
|
51
|
+
- **External** (`backendMode: external`, the default): the scraper keeps running as its own Docker container and the addon only proxies to it. Nothing about the container changes.
|
|
52
|
+
- **Embedded** (`backendMode: embedded`): the scraper runs inside the addon, and its data lives in Dominevo. Switching takes effect when the addon restarts.
|
|
53
|
+
|
|
54
|
+
### Import from Docker
|
|
55
|
+
|
|
56
|
+
Import while the backend is still set to external, then switch.
|
|
57
|
+
|
|
58
|
+
1. Stop the old container (see below) so its files are not written while you copy them.
|
|
59
|
+
2. Copy the container's whole data directory into `<dataDir>/import`, where `<dataDir>` is the addon's own data directory on the hub.
|
|
60
|
+
3. Open Settings, then "Import from Docker", and run **Preview import**. It writes nothing. It lists each collection with its row count, the credential names (never their values), the plugins found, what is not imported, and how many items already differ in the embedded store.
|
|
61
|
+
4. Run **Import now**. Rows already present and identical are left alone. Tick **Replace data already in the embedded store** to overwrite items that differ; without it those items are kept as they are.
|
|
62
|
+
5. Set the backend to embedded and restart the addon.
|
|
63
|
+
|
|
64
|
+
What is **not** imported, and why:
|
|
65
|
+
|
|
66
|
+
| Entry | Why |
|
|
67
|
+
| --- | --- |
|
|
68
|
+
| Chrome profiles | Rebuilt on first use; a profile belongs to the old container's Chrome build. |
|
|
69
|
+
| Logs | The embedded scraper writes to Dominevo's log store instead. |
|
|
70
|
+
| Captcha debug dumps | Diagnostic files of the old container. |
|
|
71
|
+
| Partial downloads | Their rows point at files on the old container's disk. |
|
|
72
|
+
| Captcha challenges | Their rows carry the session cookies of solved challenges, which are never copied. |
|
|
73
|
+
|
|
74
|
+
Plugin settings are imported as stored (plain values). The import puts exactly these in the Dominevo keychain, never in a file: the Sonarr and Radarr API keys, the Plex token, the password and private key of each network exit, and the headers of each webhook. Everything else stays a plain record.
|
|
75
|
+
|
|
76
|
+
### Where the data lives in embedded mode
|
|
77
|
+
|
|
78
|
+
- **State** (the watched list, history, downloads, sites, VPN exits, settings): Dominevo records of the addon, written behind a short debounce.
|
|
79
|
+
- **Credentials**: the Dominevo keychain.
|
|
80
|
+
- **Plugins, Chrome profile and captcha dumps**: the addon's data directory (`<dataDir>/plugins`, `<dataDir>/chrome-home`).
|
|
81
|
+
- **Downloaded binaries**: the tunnel helper (wireproxy) goes to the addon's dependency directory. Chrome is installed on first use, on linux x64 only. ffmpeg is the one the hub already provides.
|
|
82
|
+
|
|
83
|
+
### Media paths
|
|
84
|
+
|
|
85
|
+
Downloads go to the same paths the container used. On Unraid, add the `/tv` and `/movies` path mappings to the Dominevo container, with the **same container targets** as the scraper container had (`/tv`, `/movies`), pointing at the same host folders. Settings that name those paths then keep working unchanged.
|
|
86
|
+
|
|
87
|
+
### Permissions
|
|
88
|
+
|
|
89
|
+
The addon runs as uid 1001. The library folders must be writable by it: on Unraid give them to `nobody:users` with `rwX` for the group, or make them world-writable. A folder it cannot write to fails the download with a permission error in the logs.
|
|
90
|
+
|
|
91
|
+
### Stop the old container
|
|
92
|
+
|
|
93
|
+
Stop the scraper container and **turn off its autostart** (Unraid: Docker tab, container settings, Autostart off). Two scrapers on the same library download the same episodes twice, and a restarted container would race the embedded one on the same files.
|
|
94
|
+
|
|
95
|
+
### Logs
|
|
96
|
+
|
|
97
|
+
The embedded scraper's lines go to Dominevo's log store, tagged with the addon id. The scraper's Logs page lists them (the newest 2000), pages through them and downloads them. **Clear is refused** (409) because the store is shared with every other addon; there is nothing to delete from this page.
|
|
98
|
+
|
|
99
|
+
### The VPN guarantee
|
|
100
|
+
|
|
101
|
+
The rule in embedded mode is that nothing starts without the VPN.
|
|
102
|
+
|
|
103
|
+
**Level 1 (this addon, embedded mode).** The embedded scraper always runs in strict mode, whatever the VPN settings say, and a gate sits in front of all outbound work. The gate is closed from boot until the default exit's tunnel is up, its connection test passes and the leak check confirms the exit address differs from the direct one. A leak verdict that cannot be determined keeps the gate closed. While it is closed:
|
|
104
|
+
|
|
105
|
+
- the scheduler, new-episode checks, downloads, searches, catalog fetches, Chrome launches and ffmpeg runs do not start;
|
|
106
|
+
- API routes that would start outbound work answer `503 {"error":"waiting-for-vpn"}`; settings, the table, history, logs and the VPN pages stay available so you can fix the configuration;
|
|
107
|
+
- a banner on the page shows the reason, and `GET /api/vpn/gate` returns the state.
|
|
108
|
+
|
|
109
|
+
If the tunnel drops or a leak is detected, the gate closes again, new work stops and downloads in flight are paused: a direct download keeps the bytes it has and continues from them, while an HLS (m3u8) download cannot continue mid-file, so its partial file is dropped and it restarts from 0. A download that had not written anything yet is not resumed (the log says so; start it again). Nothing is requested for a paused download while the gate is closed. When the checks pass again the gate reopens by itself and the resumable downloads continue. A request that needs an exit that is not ready (a host rule, the captcha fallback) is refused, never sent through another exit. Every change of state is logged with its reason.
|
|
110
|
+
|
|
111
|
+
Local addresses bypass both the proxy and the gate, by design: private IP ranges (10/8, 172.16/12, 192.168/16, loopback, link-local and their IPv6 equivalents) and single-label host names (`sonarr`, `nas`), plus `localhost` and `.local`. A LAN service reached through a public-looking domain name goes through the VPN like any other site.
|
|
112
|
+
|
|
113
|
+
The one exception to "nothing goes out while closed" is the NordVPN server lookup (https to `api.nordvpn.com` only, sent directly, limited in time and size, every call logged), because without it an operator with no exit yet could not create the exit that opens the gate.
|
|
114
|
+
|
|
115
|
+
Limit: this is a guarantee of the application, not of the network. There is **no firewall in embedded mode**. The gate and the routing cover what the scraper does through its own network path; a plugin gets `cheerio` without `fromURL` (it opens its own connection), but a plugin that builds a module name at run time or uses `process.binding` could open a connection of its own and leave directly, and so could any other program.
|
|
116
|
+
|
|
117
|
+
**Level 2 (planned).** Run an agent inside a VPN container's network namespace and let the scraper use it, so the network itself, not the application, makes bypassing the VPN impossible.
|
|
118
|
+
|
|
119
|
+
## Known limits (embedded mode)
|
|
120
|
+
|
|
121
|
+
- **`/api/settings` returns the API keys to the admin page.** The scraper's own settings tab edits the
|
|
122
|
+
Sonarr and Radarr keys and the Plex token, so the embedded core answers them in clear on
|
|
123
|
+
`/addon/series-scraper/api/settings`, as the Docker deployment does today. The route is admin-only;
|
|
124
|
+
the addon's own `/config` endpoint never returns them. The keys are stored in the keychain.
|
|
125
|
+
- **Chrome** is installed on first use, on linux x64 only. The libraries come from a dated Ubuntu
|
|
126
|
+
snapshot (immutable), with the live archive as a fallback; every download is checked against its sha256.
|
|
127
|
+
- **A hard kill of the runner** (SIGKILL) cannot run any cleanup: tunnel children (wireproxy) and Chrome
|
|
128
|
+
are reaped by an exit handler on every other way out, but not by a SIGKILL.
|
|
129
|
+
- **A mode switch** (`backendMode`) takes effect when the addon restarts.
|
|
130
|
+
- **State that cannot be loaded** at boot keeps the addon up and answers 503 on the `api` prefix with the
|
|
131
|
+
reason; nothing is written or deleted in that case.
|
|
132
|
+
- **The VPN guarantee is level 1**: it is enforced by the scraper itself (see "The VPN guarantee"), with no kernel firewall behind it.
|
|
133
|
+
- **The gate follows the default exit.** Host rules and the captcha fallback are checked per request and refused when their exit is not ready; they do not close the gate for everything else.
|
|
134
|
+
- **Clearing the logs** is refused; the log store is shared with the hub.
|
|
135
|
+
- **Switching from embedded back to external** does not move data back: the Docker container keeps the state it had when you stopped it.
|
package/assets/icon.svg
ADDED
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="64" height="64" viewBox="0 0 64 64" fill="none">
|
|
2
|
+
<rect width="64" height="64" rx="14.5" fill="#1c1917"/>
|
|
3
|
+
<defs>
|
|
4
|
+
<linearGradient id="ss-body" x1="0.2" y1="0" x2="0.8" y2="1"><stop offset="0" stop-color="#c084fc"/><stop offset="1" stop-color="#5b21b6"/></linearGradient>
|
|
5
|
+
<linearGradient id="ss-file" x1="0" y1="0" x2="1" y2="1"><stop offset="0" stop-color="#f59e42"/><stop offset="1" stop-color="#e67e22"/></linearGradient>
|
|
6
|
+
</defs>
|
|
7
|
+
<path d="M32 0v9" stroke="#a8a29e" stroke-width="1.4"/>
|
|
8
|
+
<g stroke="#a78bfa" stroke-width="2.3" stroke-linecap="round" stroke-linejoin="round" fill="none">
|
|
9
|
+
<path d="M27.5 15.5 21 10.5 18 4.5"/><path d="M36.5 15.5 43 10.5 46 4.5"/>
|
|
10
|
+
<path d="M26.5 19 18.5 17 13 13"/><path d="M37.5 19 45.5 17 51 13"/>
|
|
11
|
+
<path d="M26.5 22.5 18.5 25.5 14 31"/><path d="M37.5 22.5 45.5 25.5 50 31"/>
|
|
12
|
+
<path d="M27.5 26 21.5 31.5 20 37"/><path d="M36.5 26 42.5 31.5 44 37"/>
|
|
13
|
+
</g>
|
|
14
|
+
<ellipse cx="32" cy="24.5" rx="7" ry="8" fill="url(#ss-body)"/>
|
|
15
|
+
<circle cx="32" cy="14" r="5" fill="url(#ss-body)"/>
|
|
16
|
+
<circle cx="30" cy="13.2" r="1.5" fill="#fafaf9"/><circle cx="34" cy="13.2" r="1.5" fill="#fafaf9"/>
|
|
17
|
+
<ellipse cx="29.5" cy="21.5" rx="2" ry="2.8" fill="#fafaf9" fill-opacity="0.25"/>
|
|
18
|
+
<path d="M32 32.5v6" stroke="#e7e5e4" stroke-width="1.4"/>
|
|
19
|
+
<path d="M23 40.5a2.5 2.5 0 0 1 2.5-2.5H36l5 5v13a2.5 2.5 0 0 1-2.5 2.5h-13A2.5 2.5 0 0 1 23 56z" fill="url(#ss-file)"/>
|
|
20
|
+
<path d="M36 38v3.5a1.5 1.5 0 0 0 1.5 1.5H41" fill="#1c1917" fill-opacity="0.25"/>
|
|
21
|
+
<path d="M29.5 45.5v8l6.5-4z" fill="#fafaf9" stroke="#fafaf9" stroke-width="1.2" stroke-linejoin="round"/>
|
|
22
|
+
</svg>
|