hoarder-app / hoarder

A self-hostable bookmark-everything app (links, notes and images) with AI-based automatic tagging and full text search
https://hoarder.app
GNU Affero General Public License v3.0
6.48k stars 235 forks source link

youtube volume #636

Closed Fuckingnameless closed 1 week ago

Fuckingnameless commented 2 weeks ago

Describe the feature you'd like

which volume are youtube videos downloaded to? i'd like them to be stored on the HDD but not sure how hoarder volumes work

Describe the benefits this would bring to existing Hoarder users

?

Can the goal of this request already be achieved via other means?

?

Have you searched for an existing open/closed issue?

Additional context

No response

MohamedBassem commented 2 weeks ago

All assets (images, video, pdfs) are in <DATA_DIR>/assets. We can probably introduce a new ASSETS_DIR env variable to customize it if needed.

Fuckingnameless commented 2 weeks ago

All assets (images, video, pdfs) are in <DATA_DIR>/assets. We can probably introduce a new ASSETS_DIR env variable to customize it if needed.

i mean which volume(mapped) on the host?

version: "3.8"
services:
  web:
    user: "${UID}:${GID}"
    image: ghcr.io/hoarder-app/hoarder:${HOARDER_VERSION:-release}
    restart: unless-stopped
    volumes:
      - ${PATH_TO_APPDATA}/hoarder/config:/data
    ports:
      - 3000:3000
    env_file:
      - hoarder.env
    environment:
      MEILI_ADDR: http://meilisearch:7700
      BROWSER_WEB_URL: http://chrome:9222
      # OPENAI_API_KEY: ...
      DATA_DIR: /data
  chrome:
    image: gcr.io/zenika-hub/alpine-chrome:123
    restart: unless-stopped
    command:
      - --no-sandbox
      - --disable-gpu
      - --disable-dev-shm-usage
      - --remote-debugging-address=0.0.0.0
      - --remote-debugging-port=9222
      - --hide-scrollbars
  meilisearch:
    user: "${UID}:${GID}"
    image: getmeili/meilisearch:v1.6
    restart: unless-stopped
    env_file:
      - hoarder.env
    environment:
      MEILI_NO_ANALYTICS: "true"
    volumes:
      - ${PATH_TO_APPDATA}/hoarder/meilisearch:/meili_data

volumes:
  meilisearch:
  data:
MohamedBassem commented 2 weeks ago

According to your compose file it's:

${PATH_TO_APPDATA}/hoarder/config

Fuckingnameless commented 2 weeks ago

According to your compose file it's:

${PATH_TO_APPDATA}/hoarder/config

Thanks a lot, will leave as is for now as i am not downloading videos

one last question, do all the services need to run as root on host? which folders they need access to?

when setting compose files i always set user:group with unprivileged ones giving access only to needed folders like appdata or media etc, in this case i give it permission to appdata folder only and it won't run, runs fine otherwise as root but that's too unsafe for my liking

chrome-1  | [1110/162249.152680:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
chrome-1  | [1110/162249.154230:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
chrome-1  | [1110/162249.154281:ERROR:bus.cc(407)] Failed to connect to the bus: Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
chrome-1  | [1110/162249.155328:WARNING:dns_config_service_linux.cc(427)] Failed to read DnsConfig.
chrome-1  | [1110/162249.188620:INFO:policy_logger.cc(145)] :components/policy/core/common/config_dir_policy_loader.cc(118) Skipping mandatory platform policies because no policy file was found at: /etc/chromium/policies/managed
chrome-1  | [1110/162249.188645:INFO:policy_logger.cc(145)] :components/policy/core/common/config_dir_policy_loader.cc(118) Skipping recommended platform policies because no policy file was found at: /etc/chromium/policies/recommended
chrome-1  | 
chrome-1  | DevTools listening on ws://0.0.0.0:9222/devtools/browser/48bf3aac-d419-4910-a7b5-0ce464933f0a
chrome-1  | [1110/162249.194882:WARNING:bluez_dbus_manager.cc(248)] Floss manager not present, cannot set Floss enable/disable.
chrome-1  | [1110/162249.214450:WARNING:sandbox_linux.cc(418)] InitializeSandbox() called with multiple threads in process gpu-process.
chrome-1  | [1110/162249.255971:WARNING:dns_config_service_linux.cc(427)] Failed to read DnsConfig.
web-1     | /package/admin/s6-overlay/libexec/preinit: info: /run belongs to uid 0 instead of 1020 - fixing it
web-1     | s6-rc: info: service s6rc-oneshot-runner: starting
web-1     | s6-rc: info: service s6rc-oneshot-runner successfully started
web-1     | s6-rc: info: service fix-attrs: starting
web-1     | s6-rc: info: service init-db-migration: starting
web-1     | s6-rc: info: service fix-attrs successfully started
web-1     | Running db migration script
web-1     | s6-rc: info: service legacy-cont-init: starting
web-1     | s6-rc: info: service legacy-cont-init successfully started
web-1     | 
web-1     | /db_migrations/index.js:815
web-1     |         [util.cppdb]: { value: new addon.Database(filename, filenameGiven, anonymous, readonly, fileMustExist, timeout, verbose || null, buffer || null) },
web-1     |                                ^
web-1     | SqliteError: unable to open database file
web-1     |     at new Database (/db_migrations/index.js:815:26)
web-1     |     at /db_migrations/index.js:11751:16
web-1     |     at /db_migrations/index.js:11825:3
web-1     |     at Object.<anonymous> (/db_migrations/index.js:11828:12)
web-1          |     at Module._compile (node:internal/modules/cjs/loader:1546:14)
web-1          |     at Object..js (node:internal/modules/cjs/loader:1689:10)
web-1          |     at Module.load (node:internal/modules/cjs/loader:1318:32)
web-1          |     at Function._load (node:internal/modules/cjs/loader:1128:12)
web-1          |     at TracingChannel.traceSync (node:diagnostics_channel:315:14)
web-1          |     at wrapModuleLoad (node:internal/modules/cjs/loader:218:24) {
web-1          |   code: 'SQLITE_CANTOPEN'
web-1          | }
web-1          | 
web-1          | Node.js v22.11.0
web-1          | s6-rc: warning: unable to start service init-db-migration: command exited 1
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)

meilisearch-1 exited with code 1
meilisearch-1  | Error: Permission denied (os error 13)
meilisearch-1  | Error: Permission denied (os error 13)
Fuckingnameless commented 2 weeks ago

for reference https://github.com/hoarder-app/hoarder/issues/606#issue-2627787161

MohamedBassem commented 2 weeks ago

@Fuckingnameless no, the services don't need to run as root. I'll fix that in the context of #606

MohamedBassem commented 1 week ago

Anything left for this issue or should we close it?