root@idmforums:/var/idmforums# ./discourse-doctor
DISCOURSE DOCTOR Wed Jun 5 00:00:48 UTC 2024
OS: Linux idmforums.com 4.15.0-32-generic #35-Ubuntu SMP Fri Aug 10 17:58:07 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
Found containers/app.yml
==================== DOCKER INFO ====================
DOCKER VERSION: Docker version 24.0.2, build cb74dfc
DOCKER PROCESSES (docker ps -a)
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
2983891adf1b local_discourse/app "/sbin/boot" 5 years ago Exited (5) 24 minutes ago app
==================== SERIOUS PROBLEM!!!! ====================
app not running!
Attempting to rebuild
==================== REBUILD LOG ====================
Ensuring launcher is up to date
Fetching origin
Launcher has diverged source, this is only expected in Dev mode
Stopping old container
+ /usr/bin/docker stop -t 60 app
app
cd /pups && git pull && git checkout v1.0.3 && /pups/bin/pups --stdin
From https://github.com/discourse/pups
17f04ec..e0ff889 master -> origin/master
* [new branch] main -> origin/main
* [new branch] stream-stdout -> origin/stream-stdout
* [new tag] v1.1.1 -> v1.1.1
* [new tag] v1.1.0 -> v1.1.0
* [new tag] v1.2.0 -> v1.2.0
* [new tag] v1.2.1 -> v1.2.1
Updating 17f04ec..e0ff889
Fast-forward
.github/workflows/ci.yml | 29 ++++++
.github/workflows/lint.yml | 27 +++++
.rubocop.yml | 3 +
Gemfile | 2 +
Guardfile | 4 +-
README.md | 21 ++++
Rakefile | 14 +--
bin/pups | 8 +-
lib/pups.rb | 32 ++++--
lib/pups/cli.rb | 92 ++++++++++-------
lib/pups/command.rb | 25 +++--
lib/pups/config.rb | 240 +++++++++++++++++++++++--------------------
lib/pups/docker.rb | 69 +++++++++++++
lib/pups/exec_command.rb | 182 ++++++++++++++++----------------
lib/pups/file_command.rb | 60 +++++------
lib/pups/merge_command.rb | 94 ++++++++---------
lib/pups/replace_command.rb | 70 +++++++------
lib/pups/runit.rb | 47 +++++----
lib/pups/version.rb | 4 +-
pups.gemspec | 37 ++++---
test/cli_test.rb | 102 +++++++++++++++---
test/config_test.rb | 215 ++++++++++++++++++++++++++++----------
test/docker_test.rb | 157 ++++++++++++++++++++++++++++
test/exec_command_test.rb | 62 ++++++-----
test/file_command_test.rb | 17 ++-
test/merge_command_test.rb | 64 ++++++------
test/replace_command_test.rb | 86 ++++++++--------
test/test_helper.rb | 2 +
28 files changed, 1158 insertions(+), 607 deletions(-)
create mode 100644 .github/workflows/ci.yml
create mode 100644 .github/workflows/lint.yml
create mode 100644 .rubocop.yml
create mode 100644 lib/pups/docker.rb
create mode 100644 test/docker_test.rb
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, [2024-06-05T00:00:57.328836 #1] INFO -- : Loading --stdin
I, [2024-06-05T00:00:57.353218 #1] INFO -- : > locale-gen $LANG && update-locale
I, [2024-06-05T00:00:57.434023 #1] INFO -- : Generating locales (this might take a while)...
Generation complete.
I, [2024-06-05T00:00:57.434294 #1] INFO -- : > mkdir -p /shared/postgres_run
I, [2024-06-05T00:00:57.439272 #1] INFO -- :
I, [2024-06-05T00:00:57.439537 #1] INFO -- : > chown postgres:postgres /shared/postgres_run
I, [2024-06-05T00:00:57.444532 #1] INFO -- :
I, [2024-06-05T00:00:57.444864 #1] INFO -- : > chmod 775 /shared/postgres_run
I, [2024-06-05T00:00:57.447574 #1] INFO -- :
I, [2024-06-05T00:00:57.447837 #1] INFO -- : > rm -fr /var/run/postgresql
I, [2024-06-05T00:00:57.450039 #1] INFO -- :
I, [2024-06-05T00:00:57.450203 #1] INFO -- : > ln -s /shared/postgres_run /var/run/postgresql
I, [2024-06-05T00:00:57.451803 #1] INFO -- :
I, [2024-06-05T00:00:57.451909 #1] INFO -- : > socat /dev/null UNIX-CONNECT:/shared/postgres_run/.s.PGSQL.5432 || exit 0 && echo postgres already running stop container ; exit 1
2024/06/05 00:00:57 socat[36] E connect(6, AF=1 "/shared/postgres_run/.s.PGSQL.5432", 36): No such file or directory
I, [2024-06-05T00:00:57.458930 #1] INFO -- :
I, [2024-06-05T00:00:57.459220 #1] INFO -- : > rm -fr /shared/postgres_run/.s*
I, [2024-06-05T00:00:57.462700 #1] INFO -- :
I, [2024-06-05T00:00:57.462930 #1] INFO -- : > rm -fr /shared/postgres_run/*.pid
I, [2024-06-05T00:00:57.466208 #1] INFO -- :
I, [2024-06-05T00:00:57.466430 #1] INFO -- : > mkdir -p /shared/postgres_run/13-main.pg_stat_tmp
I, [2024-06-05T00:00:57.469494 #1] INFO -- :
I, [2024-06-05T00:00:57.470274 #1] INFO -- : > chown postgres:postgres /shared/postgres_run/13-main.pg_stat_tmp
I, [2024-06-05T00:00:57.473224 #1] INFO -- :
I, [2024-06-05T00:00:57.480446 #1] INFO -- : File > /etc/service/postgres/run chmod: +x chown:
I, [2024-06-05T00:00:57.486006 #1] INFO -- : File > /etc/service/postgres/log/run chmod: +x chown:
I, [2024-06-05T00:00:57.489527 #1] INFO -- : File > /etc/runit/3.d/99-postgres chmod: +x chown:
I, [2024-06-05T00:00:57.492803 #1] INFO -- : File > /root/upgrade_postgres chmod: +x chown:
I, [2024-06-05T00:00:57.493015 #1] INFO -- : > chown -R root /var/lib/postgresql/13/main
I, [2024-06-05T00:00:59.462101 #1] INFO -- :
I, [2024-06-05T00:00:59.463057 #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, [2024-06-05T00:00:59.472204 #1] INFO -- :
I, [2024-06-05T00:00:59.472399 #1] INFO -- : > chown -R postgres:postgres /shared/postgres_data
I, [2024-06-05T00:00:59.525447 #1] INFO -- :
I, [2024-06-05T00:00:59.525804 #1] INFO -- : > chown -R postgres:postgres /var/run/postgresql
I, [2024-06-05T00:00:59.529442 #1] INFO -- :
I, [2024-06-05T00:00:59.529868 #1] INFO -- : > /root/upgrade_postgres
I, [2024-06-05T00:00:59.541565 #1] INFO -- :
I, [2024-06-05T00:00:59.541671 #1] INFO -- : > rm /root/upgrade_postgres
I, [2024-06-05T00:00:59.544476 #1] INFO -- :
I, [2024-06-05T00:00:59.545249 #1] INFO -- : Replacing data_directory = '/var/lib/postgresql/13/main' with data_directory = '/shared/postgres_data' in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.547238 #1] INFO -- : Replacing (?-mix:#?listen_addresses *=.*) with listen_addresses = '*' in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.553596 #1] INFO -- : Replacing (?-mix:#?synchronous_commit *=.*) with synchronous_commit = $db_synchronous_commit in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.555430 #1] INFO -- : Replacing (?-mix:#?shared_buffers *=.*) with shared_buffers = $db_shared_buffers in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.557291 #1] INFO -- : Replacing (?-mix:#?work_mem *=.*) with work_mem = $db_work_mem in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.559120 #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, [2024-06-05T00:00:59.560802 #1] INFO -- : > install -d -m 0755 -o postgres -g postgres /shared/postgres_backup
I, [2024-06-05T00:00:59.566660 #1] INFO -- :
I, [2024-06-05T00:00:59.568041 #1] INFO -- : Replacing (?-mix:#?checkpoint_segments *=.*) with checkpoint_segments = $db_checkpoint_segments in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.568400 #1] INFO -- : Replacing (?-mix:#?logging_collector *=.*) with logging_collector = $db_logging_collector in /etc/postgresql/13/main/postgresql.conf
I, [2024-06-05T00:00:59.570171 #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, [2024-06-05T00:00:59.572341 #1] INFO -- : Replacing (?-mix:^#local +replication +postgres +peer$) with local replication postgres peer in /etc/postgresql/13/main/pg_hba.conf
I, [2024-06-05T00:00:59.573673 #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, [2024-06-05T00:00:59.574292 #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, [2024-06-05T00:00:59.579227 #1] INFO -- : > sleep 5
2024-06-05 00:01:01.152 UTC [59] LOG: starting PostgreSQL 13.3 (Debian 13.3-1.pgdg100+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 8.3.0-6) 8.3.0, 64-bit
2024-06-05 00:01:01.154 UTC [59] LOG: listening on IPv4 address "0.0.0.0", port 5432
2024-06-05 00:01:01.154 UTC [59] LOG: listening on IPv6 address "::", port 5432
2024-06-05 00:01:01.163 UTC [59] LOG: listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
2024-06-05 00:01:01.176 UTC [62] LOG: database system was shut down at 2024-06-04 23:41:05 UTC
2024-06-05 00:01:01.194 UTC [59] LOG: database system is ready to accept connections
I, [2024-06-05T00:01:04.586109 #1] INFO -- :
I, [2024-06-05T00:01:04.587788 #1] INFO -- : > su postgres -c 'createdb discourse' || true
2024-06-05 00:01:04.746 UTC [72] postgres@postgres ERROR: database "discourse" already exists
2024-06-05 00:01:04.746 UTC [72] postgres@postgres STATEMENT: CREATE DATABASE discourse;
createdb: error: database creation failed: ERROR: database "discourse" already exists
I, [2024-06-05T00:01:04.751960 #1] INFO -- :
I, [2024-06-05T00:01:04.752761 #1] INFO -- : > su postgres -c 'psql discourse -c "create user discourse;"' || true
2024-06-05 00:01:04.839 UTC [83] postgres@discourse ERROR: role "discourse" already exists
2024-06-05 00:01:04.839 UTC [83] postgres@discourse STATEMENT: create user discourse;
ERROR: role "discourse" already exists
I, [2024-06-05T00:01:04.843132 #1] INFO -- :
I, [2024-06-05T00:01:04.843717 #1] INFO -- : > su postgres -c 'psql discourse -c "grant all privileges on database discourse to discourse;"' || true
I, [2024-06-05T00:01:04.917103 #1] INFO -- : GRANT
I, [2024-06-05T00:01:04.917860 #1] INFO -- : > su postgres -c 'psql discourse -c "alter schema public owner to discourse;"'
I, [2024-06-05T00:01:04.975469 #1] INFO -- : ALTER SCHEMA
I, [2024-06-05T00:01:04.975754 #1] INFO -- : > su postgres -c 'psql template1 -c "create extension if not exists hstore;"'
NOTICE: extension "hstore" already exists, skipping
I, [2024-06-05T00:01:05.035684 #1] INFO -- : CREATE EXTENSION
I, [2024-06-05T00:01:05.036028 #1] INFO -- : > su postgres -c 'psql template1 -c "create extension if not exists pg_trgm;"'
NOTICE: extension "pg_trgm" already exists, skipping
I, [2024-06-05T00:01:05.111516 #1] INFO -- : CREATE EXTENSION
I, [2024-06-05T00:01:05.111949 #1] INFO -- : > su postgres -c 'psql discourse -c "create extension if not exists hstore;"'
NOTICE: extension "hstore" already exists, skipping
I, [2024-06-05T00:01:05.170419 #1] INFO -- : CREATE EXTENSION
I, [2024-06-05T00:01:05.171033 #1] INFO -- : > su postgres -c 'psql discourse -c "create extension if not exists pg_trgm;"'
NOTICE: extension "pg_trgm" already exists, skipping
I, [2024-06-05T00:01:05.230135 #1] INFO -- : CREATE EXTENSION
I, [2024-06-05T00:01:05.230646 #1] INFO -- : > sudo -u postgres psql discourse
I, [2024-06-05T00:01:05.233158 #1] INFO -- : update pg_database set encoding = pg_char_to_encoding('UTF8') where datname = 'discourse' AND encoding = pg_char_to_encoding('SQL_ASCII');
I, [2024-06-05T00:01:05.303077 #1] INFO -- : File > /var/lib/postgresql/take-database-backup chmod: +x chown: postgres:postgres
I, [2024-06-05T00:01:05.308487 #1] INFO -- : File > /var/spool/cron/crontabs/postgres chmod: chown:
I, [2024-06-05T00:01:05.308837 #1] INFO -- : > echo postgres installed!
I, [2024-06-05T00:01:05.311334 #1] INFO -- : postgres installed!
I, [2024-06-05T00:01:05.316004 #1] INFO -- : File > /etc/service/redis/run chmod: +x chown:
I, [2024-06-05T00:01:05.322422 #1] INFO -- : File > /etc/service/redis/log/run chmod: +x chown:
I, [2024-06-05T00:01:05.327354 #1] INFO -- : File > /etc/runit/3.d/10-redis chmod: +x chown:
I, [2024-06-05T00:01:05.327925 #1] INFO -- : Replacing daemonize yes with in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.329358 #1] INFO -- : Replacing (?-mix:^pidfile.*$) with in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.329888 #1] INFO -- : > install -d -m 0755 -o redis -g redis /shared/redis_data
I, [2024-06-05T00:01:05.333762 #1] INFO -- :
I, [2024-06-05T00:01:05.334163 #1] INFO -- : Replacing (?-mix:^logfile.*$) with logfile "" in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.334652 #1] INFO -- : Replacing (?-mix:^bind .*$) with in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.335132 #1] INFO -- : Replacing (?-mix:^dir .*$) with dir /shared/redis_data in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.335627 #1] INFO -- : Replacing (?-mix:^protected-mode yes) with protected-mode no in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.336004 #1] INFO -- : Replacing # io-threads 4 with io-threads $redis_io_threads in /etc/redis/redis.conf
I, [2024-06-05T00:01:05.336339 #1] INFO -- : > echo redis installed
I, [2024-06-05T00:01:05.338198 #1] INFO -- : redis installed
I, [2024-06-05T00:01:05.338348 #1] INFO -- : > cat /etc/redis/redis.conf | grep logfile
I, [2024-06-05T00:01:05.342171 #1] INFO -- : logfile ""
I, [2024-06-05T00:01:05.342315 #1] INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2024-06-05T00:01:05.343675 #1] INFO -- : > sleep 10
176:C 05 Jun 2024 00:01:05.349 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
176:C 05 Jun 2024 00:01:05.349 # Redis version=6.2.3, bits=64, commit=00000000, modified=0, pid=176, just started
176:C 05 Jun 2024 00:01:05.349 # Configuration loaded
176:M 05 Jun 2024 00:01:05.350 * monotonic clock: POSIX clock_gettime
176:M 05 Jun 2024 00:01:05.352 * Running mode=standalone, port=6379.
176:M 05 Jun 2024 00:01:05.352 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128.
176:M 05 Jun 2024 00:01:05.352 # Server initialized
176:M 05 Jun 2024 00:01:05.352 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
176:M 05 Jun 2024 00:01:05.353 * Loading RDB produced by version 6.2.3
176:M 05 Jun 2024 00:01:05.353 * RDB age 1200 seconds
176:M 05 Jun 2024 00:01:05.353 * RDB memory usage when created 19.09 Mb
176:M 05 Jun 2024 00:01:05.797 * DB loaded from disk: 0.445 seconds
176:M 05 Jun 2024 00:01:05.797 * Ready to accept connections
I, [2024-06-05T00:01:15.346994 #1] INFO -- :
I, [2024-06-05T00:01:15.349025 #1] INFO -- : > thpoff echo "thpoff is installed!"
I, [2024-06-05T00:01:15.361046 #1] INFO -- : thpoff is installed!
I, [2024-06-05T00:01:15.361523 #1] INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_SMTP_ADDRESS"] == "smtp.example.com"; puts "Aborting! Mail is not configured!"; exit 1; end'
I, [2024-06-05T00:01:16.346114 #1] INFO -- :
I, [2024-06-05T00:01:16.347959 #1] INFO -- : > /usr/local/bin/ruby -e 'if ENV["DISCOURSE_HOSTNAME"] == "discourse.example.com"; puts "Aborting! Domain is not configured!"; exit 1; end'
I, [2024-06-05T00:01:16.442910 #1] INFO -- :
I, [2024-06-05T00:01:16.443630 #1] INFO -- : > /usr/local/bin/ruby -e 'if (ENV["DISCOURSE_CDN_URL"] || "")[0..1] == "//"; puts "Aborting! CDN must have a protocol specified. Once fixed you should rebake your posts now to correct all posts."; exit 1; end'
I, [2024-06-05T00:01:16.509332 #1] INFO -- :
I, [2024-06-05T00:01:16.510048 #1] INFO -- : > chown -R discourse /home/discourse
I, [2024-06-05T00:01:16.819286 #1] INFO -- :
I, [2024-06-05T00:01:16.819964 #1] INFO -- : > rm -f /etc/cron.d/anacron
I, [2024-06-05T00:01:16.825836 #1] INFO -- :
I, [2024-06-05T00:01:16.830100 #1] INFO -- : File > /etc/cron.d/anacron chmod: chown:
I, [2024-06-05T00:01:16.835903 #1] INFO -- : File > /etc/runit/1.d/copy-env chmod: +x chown:
I, [2024-06-05T00:01:16.842255 #1] INFO -- : File > /etc/service/unicorn/run chmod: +x chown:
I, [2024-06-05T00:01:16.849165 #1] INFO -- : File > /etc/service/nginx/run chmod: +x chown:
I, [2024-06-05T00:01:16.854937 #1] INFO -- : File > /etc/runit/3.d/01-nginx chmod: +x chown:
I, [2024-06-05T00:01:16.859605 #1] INFO -- : File > /etc/runit/3.d/02-unicorn chmod: +x chown:
I, [2024-06-05T00:01:16.859818 #1] INFO -- : Replacing # postgres with sv start postgres || exit 1 in /etc/service/unicorn/run
I, [2024-06-05T00:01:16.860146 #1] INFO -- : > exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf
I, [2024-06-05T00:01:16.863691 #1] INFO -- : > cd /var/www/discourse && git reset --hard
205:C 05 Jun 2024 00:01:16.868 # oO0OoO0OoO0Oo Redis is starting oO0OoO0OoO0Oo
205:C 05 Jun 2024 00:01:16.868 # Redis version=6.2.3, bits=64, commit=00000000, modified=0, pid=205, just started
205:C 05 Jun 2024 00:01:16.868 # Configuration loaded
205:M 05 Jun 2024 00:01:16.869 * monotonic clock: POSIX clock_gettime
205:M 05 Jun 2024 00:01:16.870 # Warning: Could not create server TCP listening socket *:6379: bind: Address already in use
205:M 05 Jun 2024 00:01:16.870 # Failed listening on port 6379 (TCP), aborting.
Checking out files: 100% (28860/28860), done.
I, [2024-06-05T00:01:21.834261 #1] INFO -- : HEAD is now at 74f71503 FEATURE: Automatically timed delete stub topics after entire topic is merged into another topic (#13187)
I, [2024-06-05T00:01:21.834977 #1] INFO -- : > cd /var/www/discourse && git clean -f
I, [2024-06-05T00:01:22.023320 #1] INFO -- :
I, [2024-06-05T00:01:22.023616 #1] INFO -- : > cd /var/www/discourse && git remote set-branches --add origin main
I, [2024-06-05T00:01:22.043353 #1] INFO -- :
I, [2024-06-05T00:01:22.043499 #1] INFO -- : > cd /var/www/discourse && git remote set-branches origin tests-passed
I, [2024-06-05T00:01:22.067432 #1] INFO -- :
I, [2024-06-05T00:01:22.067586 #1] INFO -- : > cd /var/www/discourse && git fetch --depth 1 origin tests-passed
From https://github.com/discourse/discourse
* branch tests-passed -> FETCH_HEAD
* [new branch] tests-passed -> origin/tests-passed
I, [2024-06-05T00:01:28.337837 #1] INFO -- :
I, [2024-06-05T00:01:28.338598 #1] INFO -- : > cd /var/www/discourse && git checkout tests-passed
Switched to a new branch 'tests-passed'
I, [2024-06-05T00:01:31.534502 #1] INFO -- : Branch 'tests-passed' set up to track remote branch 'tests-passed' from 'origin'.
I, [2024-06-05T00:01:31.535226 #1] INFO -- : > cd /var/www/discourse && mkdir -p tmp
I, [2024-06-05T00:01:31.540890 #1] INFO -- :
I, [2024-06-05T00:01:31.540982 #1] INFO -- : > cd /var/www/discourse && chown discourse:www-data tmp
I, [2024-06-05T00:01:31.544674 #1] INFO -- :
I, [2024-06-05T00:01:31.544787 #1] INFO -- : > cd /var/www/discourse && mkdir -p tmp/pids
I, [2024-06-05T00:01:31.549410 #1] INFO -- :
I, [2024-06-05T00:01:31.549578 #1] INFO -- : > cd /var/www/discourse && mkdir -p tmp/sockets
I, [2024-06-05T00:01:31.553124 #1] INFO -- :
I, [2024-06-05T00:01:31.553284 #1] INFO -- : > cd /var/www/discourse && touch tmp/.gitkeep
I, [2024-06-05T00:01:31.557663 #1] INFO -- :
I, [2024-06-05T00:01:31.557825 #1] INFO -- : > cd /var/www/discourse && mkdir -p /shared/log/rails
I, [2024-06-05T00:01:31.561174 #1] INFO -- :
I, [2024-06-05T00:01:31.561325 #1] INFO -- : > cd /var/www/discourse && bash -c "touch -a /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log"
I, [2024-06-05T00:01:31.569529 #1] INFO -- :
I, [2024-06-05T00:01:31.570383 #1] INFO -- : > cd /var/www/discourse && bash -c "ln -s /shared/log/rails/{production,production_errors,unicorn.stdout,unicorn.stderr,sidekiq}.log /var/www/discourse/log"
I, [2024-06-05T00:01:31.577627 #1] INFO -- :
I, [2024-06-05T00:01:31.577843 #1] INFO -- : > cd /var/www/discourse && bash -c "mkdir -p /shared/{uploads,backups}"
I, [2024-06-05T00:01:31.583781 #1] INFO -- :
I, [2024-06-05T00:01:31.583970 #1] INFO -- : > cd /var/www/discourse && bash -c "ln -s /shared/{uploads,backups} /var/www/discourse/public"
I, [2024-06-05T00:01:31.591764 #1] INFO -- :
I, [2024-06-05T00:01:31.591954 #1] INFO -- : > cd /var/www/discourse && bash -c "mkdir -p /shared/tmp/{backups,restores}"
I, [2024-06-05T00:01:31.598164 #1] INFO -- :
I, [2024-06-05T00:01:31.598326 #1] INFO -- : > cd /var/www/discourse && bash -c "ln -s /shared/tmp/{backups,restores} /var/www/discourse/tmp"
I, [2024-06-05T00:01:31.603561 #1] INFO -- :
I, [2024-06-05T00:01:31.603737 #1] INFO -- : > cd /var/www/discourse && chown -R discourse:www-data /shared/log/rails /shared/uploads /shared/backups /shared/tmp
I, [2024-06-05T00:01:32.101400 #1] INFO -- :
I, [2024-06-05T00:01:32.102064 #1] INFO -- : > cd /var/www/discourse && find public/plugins/ -maxdepth 1 -xtype l -delete
I, [2024-06-05T00:01:32.111566 #1] INFO -- :
I, [2024-06-05T00:01:32.112387 #1] INFO -- : Replacing # redis with sv start redis || exit 1 in /etc/service/unicorn/run
I, [2024-06-05T00:01:32.113094 #1] INFO -- : > cd /var/www/discourse/plugins && git clone https://github.com/discourse/docker_manager.git
Cloning into 'docker_manager'...
I, [2024-06-05T00:01:33.452577 #1] INFO -- :
I, [2024-06-05T00:01:33.454075 #1] INFO -- : > cp /var/www/discourse/config/nginx.sample.conf /etc/nginx/conf.d/discourse.conf
I, [2024-06-05T00:01:33.483225 #1] INFO -- :
I, [2024-06-05T00:01:33.483456 #1] INFO -- : > rm /etc/nginx/sites-enabled/default
I, [2024-06-05T00:01:33.486077 #1] INFO -- :
I, [2024-06-05T00:01:33.486156 #1] INFO -- : > mkdir -p /var/nginx/cache
I, [2024-06-05T00:01:33.488912 #1] INFO -- :
I, [2024-06-05T00:01:33.490137 #1] INFO -- : Replacing pid /run/nginx.pid; with daemon off; in /etc/nginx/nginx.conf
I, [2024-06-05T00:01:33.491232 #1] INFO -- : Replacing (?m-ix:upstream[^\}]+\}) with upstream discourse { server 127.0.0.1:3000; } in /etc/nginx/conf.d/discourse.conf
I, [2024-06-05T00:01:33.491544 #1] INFO -- : Replacing (?-mix:server_name.+$) with server_name _ ; in /etc/nginx/conf.d/discourse.conf
I, [2024-06-05T00:01:33.501000 #1] INFO -- : Replacing (?-mix:client_max_body_size.+$) with client_max_body_size $upload_size ; in /etc/nginx/conf.d/discourse.conf
I, [2024-06-05T00:01:33.511360 #1] INFO -- : > echo "done configuring web"
I, [2024-06-05T00:01:33.513903 #1] INFO -- : done configuring web
I, [2024-06-05T00:01:33.514452 #1] INFO -- : > cd /var/www/discourse && gem install bundler --conservative -v $(awk '/BUNDLED WITH/ { getline; gsub(/ /,""); print $0 }' Gemfile.lock)
ERROR: Error installing bundler:
bundler-2.5.3 requires Ruby version >= 3.0.0. The current ruby version is 2.7.2.137.
I, [2024-06-05T00:01:34.070583 #1] INFO -- :
I, [2024-06-05T00:01:34.072163 #1] INFO -- : Terminating async processes
I, [2024-06-05T00:01:34.072226 #1] INFO -- : Sending INT to 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 pid: 59
I, [2024-06-05T00:01:34.072309 #1] INFO -- : Sending TERM to exec chpst -u redis -U redis /usr/bin/redis-server /etc/redis/redis.conf pid: 176
2024-06-05 00:01:34.072 UTC [59] LOG: received fast shutdown request
176:signal-handler (1717545694) Received SIGTERM scheduling shutdown...
2024-06-05 00:01:34.074 UTC [59] LOG: aborting any active transactions
2024-06-05 00:01:34.080 UTC [59] LOG: background worker "logical replication launcher" (PID 68) exited with exit code 1
2024-06-05 00:01:34.081 UTC [63] LOG: shutting down
2024-06-05 00:01:34.123 UTC [59] LOG: database system is shut down
176:M 05 Jun 2024 00:01:34.124 # User requested shutdown...
176:M 05 Jun 2024 00:01:34.125 * Saving the final RDB snapshot before exiting.
176:M 05 Jun 2024 00:01:34.249 * DB saved on disk
176:M 05 Jun 2024 00:01:34.249 # Redis is now ready to exit, bye bye...
FAILED
--------------------
Pups::ExecError: cd /var/www/discourse && gem install bundler --conservative -v $(awk '/BUNDLED WITH/ { getline; gsub(/ /,""); print $0 }' Gemfile.lock) failed with return #<Process::Status: pid 314 exit 1>
Location of failure: /pups/lib/pups/exec_command.rb:112:in `spawn'
exec failed with the params {"cd"=>"$home", "hook"=>"web", "cmd"=>["gem install bundler --conservative -v $(awk '/BUNDLED WITH/ { getline; gsub(/ /,\"\"); print $0 }' Gemfile.lock)", "find $home ! -user discourse -exec chown discourse {} \\+"]}
7eb3a03475aef78c0e1752bc7845710a0ea739300bd8302356369f362d1bab6f
** 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.
==================== END REBUILD LOG ====================
Failed to rebuild app.
Checking your domain name . . .
Connection to idmforums.com succeeded.
You should probably remove any non-standard plugins and rebuild.
Attempting to restart existing container. . .
starting up existing container
+ /usr/bin/docker start app
Error response from daemon: driver failed programming external connectivity on endpoint app (6a5f876fc5e37ebb76be4bc5ef4a80ef5679fce4f4ab547eb337cafb2b1d4619): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use
Error: failed to start containers: app
Failed to restart the container.
==================== PLUGINS ====================
- git clone https://github.com/discourse/docker_manager.git
No non-official plugins detected.
See https://github.com/discourse/discourse/blob/master/lib/plugin/metadata.rb for the official list.
========================================
Discourse version at idmforums.com: NOT FOUND
Discourse version at localhost: NOT FOUND
==================== MEMORY INFORMATION ====================
RAM (MB): 8167
total used free shared buff/cache available
Mem: 7976 775 2484 6 4716 6887
Swap: 255 31 224
==================== DISK SPACE CHECK ====================
---------- OS Disk Space ----------
Filesystem Size Used Avail Use% Mounted on
/dev/sda 158G 56G 94G 38% /
==================== DISK INFORMATION ====================
Disk /dev/sda: 159.8 GiB, 171534450688 bytes, 335028224 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk /dev/sdb: 260 MiB, 272629760 bytes, 532480 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
==================== END DISK INFORMATION ====================