[Support] Joshndroid's Docker Repo Support Thread


Recommended Posts

This is the support thread for the docker templates I have added to community apps.

You can find my templates on GitHub at - Joshndroid

I am more than happy for some help/pull requests

 

Nitter

Nitter is a free and open source alternative Twitter front-end focused on privacy.

The source is available on GitHub at Zedeus/nitter

You can find my community apps page for Nitter at - /link

If you would like to roll-your-own docker straight from docker hub, have a look at the guide - Joshndroid/Nitter-Guide

Quote

Why use Nitter?
It's basically impossible to use Twitter without JavaScript enabled. If you try, you're redirected to the legacy mobile version which is awful both functionally and aesthetically. For privacy-minded folks, preventing JavaScript analytics and potential IP-based tracking is important, but apart from using the legacy mobile version and a VPN, it's impossible.

Using an instance of Nitter (hosted on a VPS for example), you can browse Twitter without JavaScript while retaining your privacy. In addition to respecting your privacy, Nitter is on average around 15 times lighter than Twitter, and in some cases serves pages faster.

In the future a simple account system will be added that lets you follow Twitter users, allowing you to have a clean chronological timeline without needing a Twitter account.

 

Nitter-Screenshot.png

 

 Libreddit

An alternative private front-end to Reddit.

The source is available on GitHub at Spikecodes/libreddit

You can find my community apps page for Libreddit at - /link

If you would like to roll-your-own docker straight from docker hub, have a look at the guide - Joshndroid/Libreddit-Guide

Quote

10 second pitch: Libreddit is a portmanteau of "libre" (meaning freedom) and "Reddit". It is a private front-end like Invidious but for Reddit. Browse the coldest takes of r/unpopularopinion without being tracked.

� Fast: written in Rust for blazing fast speeds and memory safety
☁️ Light: no JavaScript, no ads, no tracking, no bloat
� Private: all requests are proxied through the server, including media
� Secure: strong Content Security Policy prevents browser requests to Reddit

 

Libreddit-Screenshot.png

 

 Baikal

Baïkal is a lightweight CalDAV+CardDAV server. It offers an extensive web interface with easy management of users, address books and calendars. It is fast and simple to install and only needs a basic php capable server. The data can be stored in a MySQL or a SQLite database.

The source is available on GitHub at Sabre-io/Baikal

The source for the docker is available on GitHub at Ckulka/baikal-docker

You can find my community apps page for Baikal at - /link

If you would like to roll-your-own docker straight from docker hub, have a look at the guide - Joshndroid/Baikal-Guide

Quote

Baïkal allows to seamlessly access your contacts and calendars from every device. It is compatible with iOS, Mac OS X, DAVx5 on Android, Mozilla Thunderbird and every other CalDAV and CardDAV capable application. Protect your privacy by hosting calendars and contacts yourself - with Baïkal.

 

Baikal-Screenshot.png

 Invidious

An open source alternative front-end to YouTube

The source is available on GitHub at iv-org/invidious

The source for the docker is available on Quay.io at invidious/invidious

You can find my community apps page for Invidious at - /link

For setup assistance please see the Setup Post

 

Quote
  • Lightweight
  • No ads
  • No tracking
  • No JavaScript required
  • Light/Dark themes
  • Customizable homepage
  • Subscriptions independant from Google
  • Notifications for all subscribed channels
  • Audio-only mode (with background play on mobile)
  • Support for Reddit comments
  • Available in many languages, thanks to our translators
  • Does not use official YouTube APIs


Invidious-Screenshot.png

 

Bibliogram

Bibliogram is an alternative front-end for Instagram.

The source is available on Sourcehut at ~cadence/bibliogram

You can find my community apps page for Bibliogram at - /link

 

Quote

Bibliogram works without browser JavaScript, has no ads or tracking, and doesn't urge you to sign up.

 

Bibliogram-Screenshot.png

Edited by Joshndroid
  • Thanks 1
Link to comment
  • 3 weeks later...
Posted (edited)

Invidious Docker Setup Post (including database setup that MUST be undertaken)

 

Firstly I just want to take the opportunity to shout out @A75G . They have provided a second method for setting up Invidious that may be preferential to other users. They also have run through this following guide in their own setup of Invidious.

 

Invidious is a tad tricky in that it has a number of config settings that are needed as well as being fairly hard coded into other areas. Invidious can also be a bit buggy at times. I have been running Invidious as a docker for approximately 4+ weeks with constant updates occurring essentially daily. I understand that from a security standpoint this may not be preferential for systems being truly exposed to the internet. I had to weigh up the ease of use for users as well as the security implications. For me, if someone has access to my database in my setup, I have far more to worry about than the invidious docker container. For those instances requiring more security I would look at doing some manual setup in various areas to provide some more security please see here for further https://docs.invidious.io/Installation.md specifically the 'Set up PostgresSQL' section.

 

You can utilise the standard template that is bundled into the docker community apps. This will provide the basic mostly ready to go setup experience with minor changes required to the config file prior to starting invidious for the first time.

 

To generate the config file run these commands in the console

mkdir /mnt/user/appdata/invidious
mkdir /mnt/user/appdata/invidious/config
wget -O /mnt/user/appdata/invidious/config/config.yml https://raw.githubusercontent.com/iv-org/invidious/master/config/config.example.yml

Then setup your config.yml with your settings prior to starting the container.

Note if you have set up your appdata folder under the 'shares' tab to be exposed you can edit this file using a text editor such as atom. If you don't wish to use this method you can edit the file within the main console and navigate to /mnt/user/appdata/invidious/config/ and then use 'vi' editor to edit the config.yml

 

For example;

I have this config areas changed;

 

Line 14   host: (set to the IP address of your postgres installation - make sure this is on the same network as your invidious install)

 

This should be enough to get you going on a http accessed instance NOT behind a reverse proxy.

If you wish to utilise a reverse proxy utilise these config lines as well


 

Line 79   external_port: (set this to your reverse proxy port, for me its 443)


Line 98   domain: (set this to your preferred domain, such as example.com)


Line 109   https_only: (set this from false to true)

 

NOTE - Please note that there are further configs that can be set within your template.

These can be located within the invidious docs here - https://docs.invidious.io/Configuration.md

 

Network Settings Note

I am personally using a custom network 'proxynet' within unraid. I use this in conjunction with my reverse proxy to handle the SSL certs for my domain.

Using a custom network enables the ability to handle DNS between containers when both on the 'proxynet' network. thanks @Syk0tic

If you are wanting to use the br0 (or I imagine host network would be the same for this as well) please make a DNS entry for the domain 'postgres' on your DNS resolver. I use pi-hole on my network and was able to go into the setting 'local DNS' add 'postgres' to the domain field and then add in the 'IP' of the postgres database (which was also on br0) and invidious works as intended.

For those wishing to bridge I can't recommend this method until i do some further research.

 

Invidious Docker Database Setup Instructions (postgres)

 

Note - Invidious is rather picky when it comes to the database labels/naming conventions. I had tried in the past to modify these values which would lead to the container not functioning at all. I had mentioned it when talking with the Invidious devs and they have acknowledged that the names are essentially ‘hard coded’ and basically from my understanding that you may as well leave them as is unless you want some headaches.

 

I had utilised postgres10 in the past however I have this working with postgres12.5 as found on the Community apps page. I have the postgres12.5 container named postgres within the docker page of that specific docker.

Once you have your postgres database installed we need to create the invidious database
Lets assume that you have created the initial postgres database up with postgres as your user

 

psql -U postgres
CREATE DATABASE invidious;
create user kemal with encrypted password 'kemal';
GRANT ALL PRIVILEGES ON DATABASE invidious TO kemal;
exit

 

This has setup the required database of ‘invidious’ with the required username and password
Now we need to log back into the required database and create further entries for invidious to function correctly with the database.
These commands can be found within each ‘.sql’ file located at  https://github.com/iv-org/invidious/tree/master/config/sql

First log into the container with the new user and to the database

 

psql -d invidious -U kemal

 

Now you need to copy these commands. You can either copy each paragraph section from the  || CAPS LOCKS all the way to the first ; ||

OR you can copy the whole code block and paste into your terminal (I have tested this as working on a fresh setup)

 

CREATE TABLE public.annotations
(
  id text NOT NULL,
  annotations xml,
  CONSTRAINT annotations_id_key UNIQUE (id)
);

GRANT ALL ON TABLE public.annotations TO kemal;

CREATE TABLE public.videos
(
  id text NOT NULL,
  info text,
  updated timestamp with time zone,
  CONSTRAINT videos_pkey PRIMARY KEY (id)
);

GRANT ALL ON TABLE public.videos TO kemal;

CREATE UNIQUE INDEX id_idx
  ON public.videos
  USING btree
  (id COLLATE pg_catalog."default");


CREATE TABLE public.channel_videos
(
  id text NOT NULL,
  title text,
  published timestamp with time zone,
  updated timestamp with time zone,
  ucid text,
  author text,
  length_seconds integer,
  live_now boolean,
  premiere_timestamp timestamp with time zone,
  views bigint,
  CONSTRAINT channel_videos_id_key UNIQUE (id)
);

GRANT ALL ON TABLE public.channel_videos TO kemal;

CREATE INDEX channel_videos_ucid_idx
  ON public.channel_videos
  USING btree
  (ucid COLLATE pg_catalog."default");


CREATE TABLE public.channels
(
  id text NOT NULL,
  author text,
  updated timestamp with time zone,
  deleted boolean,
  subscribed timestamp with time zone,
  CONSTRAINT channels_id_key UNIQUE (id)
);

GRANT ALL ON TABLE public.channels TO kemal;

CREATE INDEX channels_id_idx
  ON public.channels
  USING btree
  (id COLLATE pg_catalog."default");

CREATE TABLE public.nonces
(
  nonce text,
  expire timestamp with time zone,
  CONSTRAINT nonces_id_key UNIQUE (nonce)
);

GRANT ALL ON TABLE public.nonces TO kemal;

CREATE INDEX nonces_nonce_idx
  ON public.nonces
  USING btree
  (nonce COLLATE pg_catalog."default");


CREATE TABLE public.users
(
  updated timestamp with time zone,
  notifications text[],
  subscriptions text[],
  email text NOT NULL,
  preferences text,
  password text,
  token text,
  watched text[],
  feed_needs_update boolean,
  CONSTRAINT users_email_key UNIQUE (email)
);

GRANT ALL ON TABLE public.users TO kemal;

CREATE UNIQUE INDEX email_unique_idx
  ON public.users
  USING btree
  (lower(email) COLLATE pg_catalog."default");

CREATE TABLE public.session_ids
(
  id text NOT NULL,
  email text,
  issued timestamp with time zone,
  CONSTRAINT session_ids_pkey PRIMARY KEY (id)
);

GRANT ALL ON TABLE public.session_ids TO kemal;

CREATE INDEX session_ids_id_idx
  ON public.session_ids
  USING btree
  (id COLLATE pg_catalog."default");


CREATE TYPE public.privacy AS ENUM
(
    'Public',
    'Unlisted',
    'Private'
);

CREATE TABLE public.playlists
(
    title text,
    id text primary key,
    author text,
    description text,
    video_count integer,
    created timestamptz,
    updated timestamptz,
    privacy privacy,
    index int8[]
);

GRANT ALL ON public.playlists TO kemal;


CREATE TABLE playlist_videos
(
    title text,
    id text,
    author text,
    ucid text,
    length_seconds integer,
    published timestamptz,
    plid text references playlists(id),
    index int8,
    live_now boolean,
    PRIMARY KEY (index,plid)
);

GRANT ALL ON TABLE public.playlist_videos TO kemal;

 

Then you have to exit

 

exit

 

Now your database should be correctly setup.

 

Maintaining the Database (which does get large over time)

please see the steps within the documentation - https://docs.invidious.io/Database-Information-and-Maintenance.md

 

 

Edited by Joshndroid
  • Thanks 1
Link to comment
3 hours ago, stefan marton said:

i have tried to install invidious with method 1 but there are this error :

from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Hostname lookup for postgres failed: No address found (Socket::Addrinfo::Error)

i checked the database is accessible

What is the name of your postgres container? I had mentioned above that I changed my postgres12.5 or postgres10 to just postgres. Give that a try and let me know how you go.

Link to comment
1 hour ago, Joshndroid said:

What is the name of your postgres container? I had mentioned above that I changed my postgres12.5 or postgres10 to just postgres. Give that a try and let me know how you go.

the name is postgress i have tried with Postgres and postgres no change

Link to comment
4 minutes ago, stefan marton said:

the name is postgress i have tried with Postgres and postgres no change

Is your postgres container on the same network as your invidious? I am reverse proxying mine through a network named proxynet both postgres and invidious are on this network type.

Link to comment
1 minute ago, Joshndroid said:

Is your postgres container on the same network as your invidious? I am reverse proxying mine through a network named proxynet both postgres and invidious are on this network type.

all two container is under bridge i use adminer to manage postgres in bridge too

Link to comment
3 minutes ago, stefan marton said:

all two container is under bridge i use adminer to manage postgres in bridge too

Have a look at your config.yml file in the invidious console. Check the content of the file for hostname/database lines (from memory its right up the top)

 

That error is basically when invidious can't find the database. Its picky as heck.

 

I had a feeling that there may be some teething issues. I wrote the guide mostly well after I had set my instance up. There is potential I have missed a step.

 

I am unable to be at my PC at present but will take another look when I get home. 

Link to comment
3 hours ago, Joshndroid said:

What is the name of your postgres container? I had mentioned above that I changed my postgres12.5 or postgres10 to just postgres. Give that a try and let me know how you go.

I am having the same issue. I have named my docker container postgres with no change.

 

I have confirmed that the database is running and accessible both locally on the postgres container and remotely from my other linux machine using a postgres client.

 

My DB_HOST is the ip address of my unraid machine, username/password/DB are all left at default in the template. I followed the instructions provided above to setup the postgres database using the kemal/kemal username/password.

Link to comment
1 hour ago, Nesquik said:

I am having the same issue. I have named my docker container postgres with no change.

 

I have confirmed that the database is running and accessible both locally on the postgres container and remotely from my other linux machine using a postgres client.

 

My DB_HOST is the ip address of my unraid machine, username/password/DB are all left at default in the template. I followed the instructions provided above to setup the postgres database using the kemal/kemal username/password.

Thanks mate for the feedback.

I can't get in to do what I need to on mobile.

 

Have a look at your config.yml file in the console. Check the database.

 

Otherwise just hang on for a bit longer and I'll take a look when I get home

Link to comment
18 minutes ago, Joshndroid said:

Thanks mate for the feedback.

I can't get in to do what I need to on mobile.

 

Have a look at your config.yml file in the console. Check the database.

 

Otherwise just hang on for a bit longer and I'll take a look when I get home

No worries! I appreciate you taking a look at this.

  • Like 1
Link to comment
Posted (edited)
10 hours ago, stefan marton said:

all two container is under bridge i use adminer to manage postgres in bridge too

 

7 hours ago, Nesquik said:

No worries! I appreciate you taking a look at this.

 

I have nuked my invidious container on my local machine in the hope of replicating your issues and run again through my guide.

I have found it easier to utilise the 'method 2' after my nuking so I have changed this to the default and only method.

I am updating the template to remove those lines as in method 2 as well as updated the other setup pieces.

I have been able to basically get mine working again in the last hour from scratch after spending the first hour trouble shooting through methods.

 

I have updated the template on my end and it take a little bit of time for it to be updated within unraid community apps section. It removes the lines I had extra above (which I have now removed in the first thread for simplicity sake).

 

I have not changed anything in relation to postgres on my end (apart from backing mine up, nuking it, playing with the check_tables config [which didnt work, citing permissions issues] and restoring). I can guess that due to using method 2 and essentially directly utilising the IP of your database, the naming requirement from progres10 or whatever to postgres will probably also be moot.

 

I assume you may need to nuke your invidious from your system (if you have setup your database you can actually keep this ready for the newer template/setup). Then just wait a tad for unraid to recognise and import my changes, recheck my guide and try again.

 

Please let me know how you go.\

Edited by Joshndroid
Link to comment
21 minutes ago, Joshndroid said:

 

 

I have nuked my invidious container on my local machine in the hope of replicating your issues and run again through my guide.

I have found it easier to utilise the 'method 2' after my nuking so I have changed this to the default and only method.

I am updating the template to remove those lines as in method 2 as well as updated the other setup pieces.

I have been able to basically get mine working again in the last hour from scratch after spending the first hour trouble shooting through methods.

 

I have updated the template on my end and it take a little bit of time for it to be updated within unraid community apps section. It removes the lines I had extra above (which I have now removed in the first thread for simplicity sake).

 

I have not changed anything in relation to postgres on my end (apart from backing mine up, nuking it, playing with the check_tables config [which didnt work, citing permissions issues] and restoring). I can guess that due to using method 2 and essentially directly utilising the IP of your database, the naming requirement from progres10 or whatever to postgres will probably also be moot.

 

I assume you may need to nuke your invidious from your system (if you have setup your database you can actually keep this ready for the newer template/setup). Then just wait a tad for unraid to recognise and import my changes, recheck my guide and try again.

 

Please let me know how you go.\

Thank you so much for your hard work. I will go ahead and remove the invidious container/image and wipe the folder.

 

I will get back to you soon when I get time to experiment a bit more.

Link to comment
15 minutes ago, Nesquik said:

Thank you so much for your hard work. I will go ahead and remove the invidious container/image and wipe the folder.

 

I will get back to you soon when I get time to experiment a bit more.

Thanks mate, apologies for the muck around. I knew invidious was going to be a pain and it hasn't disappointed thus far lol.

Link to comment

I tried to setup this container today following the new instructions (it failed to work yesterday with the original instructions). Unfortunately, it still has the same error for me as yesterday.

 

Both containers are on my bro.10 network with static IPs. 

 

config.yml

db:
  user: kemal
  password: kemal
  host: 192.168.20.231
  port: 5432
  dbname: invidious

 

error from invidious log

from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Cannot establish connection (PQ::ConnectionError)
from lib/pg/src/pq/connection.cr:34:9 in 'initialize'
from lib/pg/src/pq/connection.cr:19:5 in 'new'
from lib/pg/src/pg/connection.cr:13:23 in 'initialize'
from lib/pg/src/pg/connection.cr:7:5 in 'new'
from lib/pg/src/pg/driver.cr:3:5 in 'build_connection'
from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Hostname lookup for postgres failed: No address found (Socket::Addrinfo::Error)

 

Link to comment
2 hours ago, Mathervius said:

I tried to setup this container today following the new instructions (it failed to work yesterday with the original instructions). Unfortunately, it still has the same error for me as yesterday.

 

Both containers are on my bro.10 network with static IPs. 

 

config.yml

db:
  user: kemal
  password: kemal
  host: 192.168.20.231
  port: 5432
  dbname: invidious

 

error from invidious log

from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Cannot establish connection (PQ::ConnectionError)
from lib/pg/src/pq/connection.cr:34:9 in 'initialize'
from lib/pg/src/pq/connection.cr:19:5 in 'new'
from lib/pg/src/pg/connection.cr:13:23 in 'initialize'
from lib/pg/src/pg/connection.cr:7:5 in 'new'
from lib/pg/src/pg/driver.cr:3:5 in 'build_connection'
from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Hostname lookup for postgres failed: No address found (Socket::Addrinfo::Error)

 

Same issue for me as well.

I removed the invidious image, deleted app data.

Setup the config folder as instructed with the config.yaml file

Tried localhost and my towers IP address as the host and both get connection refused / not able to connect to the postgres DB.

 

I did find that my default appdata directory is: /mnt/user/docker/appdata/invidious

but, the folder I made for the /config was here: /mnt/user/appdata/invidious/

So I updated the template, but unfortunately that did not fix it either.

 

 

Edited by Nesquik
Link to comment

The problem is that the invidious container is trying to connect via a dns name (i.e postgres.) By design bro or bridge networks don't have container to container dns. when you create a custom network (i.e proxynet) it enables DNS for that network, there for adding both invidious and postgres to the custom network is why this works for Joshndroid.

  • Thanks 1
Link to comment
18 minutes ago, Syk0tic said:

The problem is that the invidious container is trying to connect via a dns name (i.e postgres.) By design bro or bridge networks don't have container to container dns. when you create a custom network (i.e proxynet) it enables DNS for that network, there for adding both invidious and postgres to the custom network is why this works for Joshndroid.

Good Catch- I just changed both of my containers (postgres and invidious) to the LSIO from br0 network and it started right up.

Link to comment
6 hours ago, Mathervius said:

I tried to setup this container today following the new instructions (it failed to work yesterday with the original instructions). Unfortunately, it still has the same error for me as yesterday.

 

Both containers are on my bro.10 network with static IPs. 

 

config.yml

db:
  user: kemal
  password: kemal
  host: 192.168.20.231
  port: 5432
  dbname: invidious

 

error from invidious log

from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Cannot establish connection (PQ::ConnectionError)
from lib/pg/src/pq/connection.cr:34:9 in 'initialize'
from lib/pg/src/pq/connection.cr:19:5 in 'new'
from lib/pg/src/pg/connection.cr:13:23 in 'initialize'
from lib/pg/src/pg/connection.cr:7:5 in 'new'
from lib/pg/src/pg/driver.cr:3:5 in 'build_connection'
from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Hostname lookup for postgres failed: No address found (Socket::Addrinfo::Error)

 

 

Try using a different network that enables container to container DNS as mentioned by @Syk0tic

 

3 hours ago, Syk0tic said:

The problem is that the invidious container is trying to connect via a dns name (i.e postgres.) By design bro or bridge networks don't have container to container dns. when you create a custom network (i.e proxynet) it enables DNS for that network, there for adding both invidious and postgres to the custom network is why this works for Joshndroid.

 

Thanks mate for the insight on the network stuff in unraid :)

 

2 hours ago, Nesquik said:

Good Catch- I just changed both of my containers (postgres and invidious) to the LSIO from br0 network and it started right up.

 

Good to hear its working!

Link to comment
7 hours ago, Mathervius said:

I tried to setup this container today following the new instructions (it failed to work yesterday with the original instructions). Unfortunately, it still has the same error for me as yesterday.

 

Both containers are on my bro.10 network with static IPs. 

 

config.yml

db:
  user: kemal
  password: kemal
  host: 192.168.20.231
  port: 5432
  dbname: invidious

 

error from invidious log

from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Cannot establish connection (PQ::ConnectionError)
from lib/pg/src/pq/connection.cr:34:9 in 'initialize'
from lib/pg/src/pq/connection.cr:19:5 in 'new'
from lib/pg/src/pg/connection.cr:13:23 in 'initialize'
from lib/pg/src/pg/connection.cr:7:5 in 'new'
from lib/pg/src/pg/driver.cr:3:5 in 'build_connection'
from lib/db/src/db/database.cr:57:16 in '->'
from /usr/share/crystal/src/primitives.cr:266:3 in 'build_resource'
from lib/db/src/db/pool.cr:47:34 in 'initialize'
from lib/db/src/db/pool.cr:40:5 in 'new:initial_pool_size:max_pool_size:max_idle_pool_size:checkout_timeout:retry_attempts:retry_delay'
from lib/db/src/db/database.cr:56:15 in 'initialize'
from lib/db/src/db/database.cr:49:5 in 'new'
from lib/db/src/db.cr:155:5 in 'build_database'
from lib/db/src/db.cr:119:5 in 'open'
from /usr/share/crystal/src/kernel.cr:386:3 in '???'
from src/invidious.cr:38:1 in '__crystal_main'
from /usr/share/crystal/src/crystal/main.cr:110:5 in 'main_user_code'
from /usr/share/crystal/src/crystal/main.cr:96:7 in 'main'
from /usr/share/crystal/src/crystal/main.cr:119:3 in 'main'
from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Caused by: Hostname lookup for postgres failed: No address found (Socket::Addrinfo::Error)

 

 

3 hours ago, Nesquik said:

Good Catch- I just changed both of my containers (postgres and invidious) to the LSIO from br0 network and it started right up.

 

If you want to use this docker container using the br0 network based on the information i gleaned from above

you will need to create a local custom DNS entry pointing to your database.

I use pi-hole on my network so I was able to easily set 'postgres' to the database IP and it starts straight back up.

If your wanting to use 'bridge' i was unable to get that working as yet, i will have another look at that later.

Link to comment

I have made further update to the Invidious setup post regarding network choices based on the above. At this time I can only recommend a br0 network type (and loosely host network) as well as the use of a custom network as I have both of these methods working. Check the setup post for the network note and potential further setup involved.

Link to comment
59 minutes ago, Joshndroid said:

Thanks mate for the insight on the network stuff in unraid :)

I have to thank you as well! I tried and failed to deploy from their instructions a few times but I don’t think I realized how hard coded the db info was. Glad I could give something back. Cheers!

Link to comment

Thanks Josh! I will keep it on the LSIO network since I am going to put it behind the reverse proxy. 

 

Do most of the features work? I don't think I could get it to login. My goal is to get my YouTube subscriptions loaded.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.