Failed to restart the container?

So I just set everything up on my Ubuntu 20.04 LTS machine (first time discourse setup on here) and I keep getting Failed to restart the container. (also discourse-doctor outputted this at the top).

Also when attempting to send test email, Error: No such container: app

On the subject of failed to restart the container:

Unable to find image 'local_discourse/app:latest' locally
docker: Error response from daemon: pull access denied for local_discourse/app, repository does not exist or may require 'docker login': denied: requested access to the resource is denied.
See 'docker run --help'.
Failed to restart the container.

Also I have this when using discourse-setup:

./discourse-setup
The configuration file containers/app.yml already exists!

. . . reconfiguring . . .


Saving old file as app.yml.2021-05-12-102820.bak
Stopping existing container in 5 seconds or Control-C to cancel.
app was not started !
./discourse-doctor may help diagnose the problem.

When using launcher rebuild app:

Ensuring launcher is up to date
Fetching origin
Launcher is up-to-date
cd /pups && git pull && git checkout v1.0.3 && /pups/bin/pups --stdin
Already up to date.
Note: checking out 'v1.0.3'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

HEAD is now at d1db030 cut a new version
I, [2021-05-12T09:50:18.718488 #1]  INFO -- : Loading --stdin
I, [2021-05-12T09:50:18.725717 #1]  INFO -- : > locale-gen $LANG && update-locale
I, [2021-05-12T09:50:18.765005 #1]  INFO -- : Generating locales (this might take a while)...
Generation complete.

I, [2021-05-12T09:50:18.765246 #1]  INFO -- : > mkdir -p /shared/postgres_run
I, [2021-05-12T09:50:18.770660 #1]  INFO -- : 
I, [2021-05-12T09:50:18.771117 #1]  INFO -- : > chown postgres:postgres /shared/postgres_run
I, [2021-05-12T09:50:18.775863 #1]  INFO -- : 
I, [2021-05-12T09:50:18.776526 #1]  INFO -- : > chmod 775 /shared/postgres_run
I, [2021-05-12T09:50:18.784118 #1]  INFO -- : 
I, [2021-05-12T09:50:18.784732 #1]  INFO -- : > rm -fr /var/run/postgresql
I, [2021-05-12T09:50:18.789096 #1]  INFO -- : 
I, [2021-05-12T09:50:18.789666 #1]  INFO -- : > ln -s /shared/postgres_run /var/run/postgresql
I, [2021-05-12T09:50:18.794763 #1]  INFO -- : 
I, [2021-05-12T09:50:18.795410 #1]  INFO -- : > socat /dev/null UNIX-CONNECT:/shared/postgres_run/.s.PGSQL.5432 || exit 0 && echo postgres already running stop container ; exit 1
2021/05/12 09:50:18 socat[28] E connect(6, AF=1 "/shared/postgres_run/.s.PGSQL.5432", 36): No such file or directory
I, [2021-05-12T09:50:18.802633 #1]  INFO -- : 
I, [2021-05-12T09:50:18.802834 #1]  INFO -- : > rm -fr /shared/postgres_run/.s*
I, [2021-05-12T09:50:18.807914 #1]  INFO -- : 
I, [2021-05-12T09:50:18.808476 #1]  INFO -- : > rm -fr /shared/postgres_run/*.pid
I, [2021-05-12T09:50:18.814386 #1]  INFO -- : 
I, [2021-05-12T09:50:18.814595 #1]  INFO -- : > mkdir -p /shared/postgres_run/13-main.pg_stat_tmp
I, [2021-05-12T09:50:18.819542 #1]  INFO -- : 
I, [2021-05-12T09:50:18.820160 #1]  INFO -- : > chown postgres:postgres /shared/postgres_run/13-main.pg_stat_tmp
I, [2021-05-12T09:50:18.824774 #1]  INFO -- : 
I, [2021-05-12T09:50:18.834404 #1]  INFO -- : File > /etc/service/postgres/run  chmod: +x  chown: 
I, [2021-05-12T09:50:18.844948 #1]  INFO -- : File > /etc/service/postgres/log/run  chmod: +x  chown: 
I, [2021-05-12T09:50:18.853870 #1]  INFO -- : File > /etc/runit/3.d/99-postgres  chmod: +x  chown: 
I, [2021-05-12T09:50:18.862785 #1]  INFO -- : File > /root/upgrade_postgres  chmod: +x  chown: 
I, [2021-05-12T09:50:18.863660 #1]  INFO -- : > chown -R root /var/lib/postgresql/13/main
I, [2021-05-12T09:50:50.039399 #1]  INFO -- : 
I, [2021-05-12T09:50:50.039806 #1]  INFO -- : > [ ! -e /shared/postgres_data ] && install -d -m 0755 -o postgres -g postgres /shared/postgres_data && sudo -E -u postgres /usr/lib/postgresql/13/bin/initdb -D /shared/postgres_data || exit 0
I, [2021-05-12T09:50:50.045475 #1]  INFO -- : 
I, [2021-05-12T09:50:50.045688 #1]  INFO -- : > chown -R postgres:postgres /shared/postgres_data
I, [2021-05-12T09:50:50.058739 #1]  INFO -- : 
I, [2021-05-12T09:50:50.059712 #1]  INFO -- : > chown -R postgres:postgres /var/run/postgresql
I, [2021-05-12T09:50:50.064419 #1]  INFO -- : 
I, [2021-05-12T09:50:50.064669 #1]  INFO -- : > /root/upgrade_postgres
I, [2021-05-12T09:50:50.072435 #1]  INFO -- : 
I, [2021-05-12T09:50:50.073015 #1]  INFO -- : > rm /root/upgrade_postgres
I, [2021-05-12T09:50:50.078047 #1]  INFO -- : 
I, [2021-05-12T09:50:50.079038 #1]  INFO -- : Replacing data_directory = '/var/lib/postgresql/13/main' with data_directory = '/shared/postgres_data' in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.080583 #1]  INFO -- : Replacing (?-mix:#?listen_addresses *=.*) with listen_addresses = '*' in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.081391 #1]  INFO -- : Replacing (?-mix:#?synchronous_commit *=.*) with synchronous_commit = $db_synchronous_commit in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.082345 #1]  INFO -- : Replacing (?-mix:#?shared_buffers *=.*) with shared_buffers = $db_shared_buffers in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.083082 #1]  INFO -- : Replacing (?-mix:#?work_mem *=.*) with work_mem = $db_work_mem in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.083973 #1]  INFO -- : Replacing (?-mix:#?default_text_search_config *=.*) with default_text_search_config = '$db_default_text_search_config' in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.084828 #1]  INFO -- : > install -d -m 0755 -o postgres -g postgres /shared/postgres_backup
I, [2021-05-12T09:50:50.090354 #1]  INFO -- : 
I, [2021-05-12T09:50:50.090969 #1]  INFO -- : Replacing (?-mix:#?checkpoint_segments *=.*) with checkpoint_segments = $db_checkpoint_segments in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.092485 #1]  INFO -- : Replacing (?-mix:#?logging_collector *=.*) with logging_collector = $db_logging_collector in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.093092 #1]  INFO -- : Replacing (?-mix:#?log_min_duration_statement *=.*) with log_min_duration_statement = $db_log_min_duration_statement in /etc/postgresql/13/main/postgresql.conf
I, [2021-05-12T09:50:50.094187 #1]  INFO -- : Replacing (?-mix:^#local +replication +postgres +peer$) with local replication postgres  peer in /etc/postgresql/13/main/pg_hba.conf
I, [2021-05-12T09:50:50.094726 #1]  INFO -- : Replacing (?-mix:^host.*all.*all.*127.*$) with host all all 0.0.0.0/0 md5 in /etc/postgresql/13/main/pg_hba.conf
I, [2021-05-12T09:50:50.095089 #1]  INFO -- : > HOME=/var/lib/postgresql USER=postgres exec chpst -u postgres:postgres:ssl-cert -U postgres:postgres:ssl-cert /usr/lib/postgresql/13/bin/postmaster -D /etc/postgresql/13/main
I, [2021-05-12T09:50:50.098332 #1]  INFO -- : > sleep 5
2021-05-12 09:50:50.117 UTC [51] FATAL:  data directory "/shared/postgres_data" has invalid permissions
2021-05-12 09:50:50.117 UTC [51] DETAIL:  Permissions should be u=rwx (0700) or u=rwx,g=rx (0750).
I, [2021-05-12T09:50:55.105204 #1]  INFO -- : 
I, [2021-05-12T09:50:55.105785 #1]  INFO -- : > su postgres -c 'createdb discourse' || true
createdb: error: could not connect to database template1: could not connect to server: No such file or directory
	Is the server running locally and accepting
	connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?
I, [2021-05-12T09:50:55.179154 #1]  INFO -- : 
I, [2021-05-12T09:50:55.179389 #1]  INFO -- : > su postgres -c 'psql discourse -c "create user discourse;"' || true
psql: error: could not connect to server: No such file or directory
	Is the server running locally and accepting
	connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?
I, [2021-05-12T09:50:55.272457 #1]  INFO -- : 
I, [2021-05-12T09:50:55.272673 #1]  INFO -- : > su postgres -c 'psql discourse -c "grant all privileges on database discourse to discourse;"' || true
psql: error: could not connect to server: No such file or directory
	Is the server running locally and accepting
	connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?
I, [2021-05-12T09:50:55.370163 #1]  INFO -- : 
I, [2021-05-12T09:50:55.370560 #1]  INFO -- : > su postgres -c 'psql discourse -c "alter schema public owner to discourse;"'
psql: error: could not connect to server: No such file or directory
	Is the server running locally and accepting
	connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?
I, [2021-05-12T09:50:55.462132 #1]  INFO -- : 
I, [2021-05-12T09:50:55.462739 #1]  INFO -- : Terminating async processes


FAILED
--------------------
Pups::ExecError: su postgres -c 'psql discourse -c "alter schema public owner to discourse;"' failed with return #<Process::Status: pid 77 exit 2>
Location of failure: /pups/lib/pups/exec_command.rb:112:in `spawn'
exec failed with the params "su postgres -c 'psql $db_name -c \"alter schema public owner to $db_user;\"'"
e6e8899182c075f3a312723ed5ed1935643882a33b9e6adf5a2cc00212962753
** FAILED TO BOOTSTRAP ** please scroll up and look for earlier error messages, there may be more than one.
./discourse-doctor may help diagnose the problem.

Please help. This is the first time ever setting up on my Ubuntu 20 PC.

Bump ^

Having this issue too. Instead I am getting a rake error.

location of failure: /pups/lib/pups/exec_command.rb:112:in `spawn'

I don’t know why spawn has one ` and one '.

Full Error