No puedo hacer que Discourse funcione de nuevo

Hola:
He estado ejecutando Discourse durante los últimos meses sin problemas.
Tuve que reiniciar el host y ahora no puedo hacer que Discourse vuelva a funcionar.

/var/discourse# ./launcher rebuild app

Asegurando que el lanzador esté actualizado

Obteniendo origen

El lanzador está actualizado

cat: 80:80: No existe el archivo o directorio

cat: 443:443: No existe el archivo o directorio

cd /pups && git pull && /pups/bin/pups --stdin

/usr/bin/docker: formato de referencia no válido: el nombre del repositorio debe estar en minúsculas.

Consulta '/usr/bin/docker run --help'.

cat: cids/app_bootstrap.cid: No existe el archivo o directorio

"docker rm" requiere al menos 1 argumento.

Consulta 'docker rm --help'.

Uso: docker rm [OPCIONES] CONTENEDOR [CONTENEDOR...]

Elimina uno o más contenedores

rm: no se puede eliminar 'cids/app_bootstrap.cid': No existe el archivo o directorio

** FALLO EN EL ARRANQUE ** Por favor, desplace hacia arriba y busque mensajes de error anteriores; puede haber más de uno.

./discourse-doctor puede ayudar a diagnosticar el problema.

Los comandos “run” y “bootstrap” hacen lo mismo :frowning:

Doctor dice:

./discourse-doctor 
DISCOURSE DOCTOR Sun Feb 16 11:59:15 CET 2020
SO: Linux XXXXXXXXXXXX 3.16.0-7-amd64 #1 SMP Debian 3.16.59-1 (2018-10-03) x86_64 GNU/Linux


Se encontró containers/app.yml

==================== CONFIGURACIÓN YML ====================
awk: no es una opción: --field-separator=:
DISCOURSE_HOSTNAME=
awk: no es una opción: --field-separator=:
SMTP_ADDRESS=
awk: no es una opción: --field-separator=:
DEVELOPER_EMAILS=
awk: no es una opción: --field-separator=:
SMTP_PASSWORD=
awk: no es una opción: --field-separator=:
SMTP_PORT=
awk: no es una opción: --field-separator=:
SMTP_USER_NAME=
awk: no es una opción: --field-separator=:
LETSENCRYPT_ACCOUNT_EMAIL=

==================== INFORMACIÓN DE DOCKER ====================
VERSIÓN DE DOCKER: Docker version 18.06.3-ce, build d7080c1

PROCESOS DE DOCKER (docker ps -a)

ID DEL CONTENEDOR        IMAGEN               COMANDO             CREADO             ESTADO              PUERTOS               NOMBRES

==================== PROBLEMA GRAVE!!!! ====================
¡app no se está ejecutando!
Intentando reconstruir
==================== REGISTRO DE RECONSTRUCCIÓN ====================
Asegurando que el lanzador esté actualizado
Obteniendo origen
El lanzador está actualizado
cat: 80:80: No existe el archivo o directorio
cat: 443:443: No existe el archivo o directorio
cd /pups && git pull && /pups/bin/pups --stdin
/usr/bin/docker: formato de referencia no válido: el nombre del repositorio debe estar en minúsculas.
Consulta '/usr/bin/docker run --help'.
cat: cids/app_bootstrap.cid: No existe el archivo o directorio
"docker rm" requiere al menos 1 argumento.
Consulta 'docker rm --help'.

Uso:  docker rm [OPCIONES] CONTENEDOR [CONTENEDOR...]

Elimina uno o más contenedores
rm: no se puede eliminar 'cids/app_bootstrap.cid': No existe el archivo o directorio
** FALLO EN EL ARRANQUE ** Por favor, desplace hacia arriba y busque mensajes de error anteriores; puede haber más de uno.
./discourse-doctor puede ayudar a diagnosticar el problema.
==================== FIN DEL REGISTRO DE RECONSTRUCCIÓN ====================
No se pudo reconstruir la aplicación.

Verificando tu nombre de dominio . . .

Conexión a 443 exitosa.
Probablemente debas eliminar cualquier plugin no estándar y reconstruir.
Intentando reiniciar el contenedor existente . . . 

cat: 80:80: No existe el archivo o directorio
cat: 443:443: No existe el archivo o directorio
+ /usr/bin/docker run --shm-size=512m -d --restart=always '#<NoMethodError: undefined method `[]'\'' for false:FalseClass>' '#<NoMethodError: undefined method `[]'\'' for false:FalseClass>' -e LANG=en_US.UTF-8 -e RAILS_ENV=production -e UNICORN_WORKERS=4 -e UNICORN_SIDEKIQS=1 -e RUBY_GLOBAL_METHOD_CACHE_SIZE=131072 -e RUBY_GC_HEAP_GROWTH_MAX_SLOTS=40000 -e RUBY_GC_HEAP_INIT_SLOTS=400000 -e RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=1.5 -e DISCOURSE_DB_SOCKET=/var/run/postgresql -e DISCOURSE_DB_HOST= -e DISCOURSE_DB_PORT= -e LETSENCRYPT_DIR=/shared/letsencrypt -e DISCOURSE_HOSTNAME=XXXXXXXXXXXX -e DISCOURSE_DEVELOPER_EMAILS=XXXXXXXXXXXX -e DISCOURSE_SMTP_ADDRESS=XXXXXXXXXXXX -e DISCOURSE_SMTP_PORT=587 -e DISCOURSE_SMTP_USER_NAME=XXXXXXXXXXXX -e DISCOURSE_SMTP_PASSWORD=XXXXXXXXXXXX -e DISCOURSE_SMTP_ENABLE_START_TLS=false -e LETSENCRYPT_ACCOUNT_EMAIL=XXXXXXXXXXXX '#<NoMethodError: undefined method `[]'\'' for false:FalseClass>' '#<NoMethodError: undefined method `[]'\'' for false:FalseClass>' -h vps659319-app -e DOCKER_HOST_IP=172.17.0.1 --name app -t '#<NoMethodError: undefined method `[]'\'' for false:FalseClass>' '#<NoMethodError: undefined method `[]'\'' for false:FalseClass>' -v /var/discourse/shared/standalone:/shared -v /var/discourse/shared/standalone/log/var-log:/var/log --mac-address 02:62:5b:d4:b7:80 local_discourse/app /sbin/boot
/usr/bin/docker: formato de referencia no válido: el nombre del repositorio debe estar en minúsculas.
Consulta '/usr/bin/docker run --help'.
No se pudo reiniciar el contenedor.


==================== PLUGINS ====================
          - git clone https://github.com/discourse/docker_manager.git
          - git clone https://github.com/discourse/discourse-plugin-linkedin-auth.git
          - git clone https://github.com/discourse/discourse-oauth2-basic.git
          - git clone https://github.com/discourse/discourse-solved.git
          - git clone https://github.com/discourse/discourse-voting.git
          - git clone https://github.com/discourse/discourse-assign.git
          - git clone https://github.com/discourse/discourse-staff-notes.git
          - git clone https://github.com/discourse/discourse-checklist.git
          - git clone https://github.com/discourse/discourse-social-share.git
          - git clone https://github.com/rcfox/Discourse-LinkedIn-Sharing-Button.git
          - git clone https://github.com/BeXcellent/discourse-allowiframe.git

ADVERTENCIA:
Parece que tienes plugins no oficiales.
Si estás teniendo problemas, deberías desactivarlos e intentar reconstruir de nuevo.

Consulta https://github.com/discourse/discourse/blob/master/lib/plugin/metadata.rb para ver la lista oficial.

========================================
Versión de Discourse en : NO ENCONTRADA
Versión de Discourse en localhost: NO ENCONTRADA


==================== INFORMACIÓN DE MEMORIA ====================
RAM (MB): 2009

             total       usada       libre     compartida     buffers     caché
Mem:          1962       1819        142         45         86        586
-/+ buffers/cache:       1146        815
Swap:         2047        190       1857

==================== COMPROBACIÓN DE ESPACIO EN DISCO ====================
---------- Espacio en disco del SO ----------
Sistema de archivos      Tamaño  Usado Disp Uso% Montado en
/dev/sda1        20G  9.1G  9.7G  49% /

==================== INFORMACIÓN DEL DISCO ====================

Disco /dev/sdb: 50 GiB, 53687091200 bytes, 104857600 sectores
Unidades: sectores de 1 * 512 = 512 bytes
Tamaño del sector (lógico/físico): 512 bytes / 512 bytes
Tamaño de E/S (mínimo/óptimo): 512 bytes / 512 bytes
Disco /dev/sda: 20 GiB, 21474836480 bytes, 41943040 sectores
Unidades: sectores de 1 * 512 = 512 bytes
Tamaño del sector (lógico/físico): 512 bytes / 512 bytes
Tamaño de E/S (mínimo/óptimo): 512 bytes / 512 bytes
Tipo de etiqueta de disco: dos
Identificador de disco: 0x7f0953e7

Dispositivo     Arranque Inicio      Fin  Sectores Tamaño Id Tipo
/dev/sda1  *     2048 41941883 41939836  20G 83 Linux

==================== FIN DE LA INFORMACIÓN DEL DISCO ====================

==================== PRUEBA DE CORREO ====================
Para una prueba robusta, obtén una dirección en http://www.mail-tester.com/
O simplemente envía un mensaje de prueba a ti mismo.
¿Dirección de correo para la prueba? ('n' para omitir) []: XXXXXXXXXXXX
Enviando correo a XXXXXXXXXXXX . . . 
Error: No existe el contenedor: app

Sustituyendo: SMTP_PASSWORD
Sustituyendo: LETSENCRYPT_ACCOUNT_EMAIL
Sustituyendo: DEVELOPER_EMAILS
Sustituyendo: DISCOURSE_DB_PASSWORD
Sustituyendo: Enviando correo a

==================== ¡LISTO! ====================

Puedes examinar la salida de este script con 
LESS=-Ri less /tmp/discourse-debug.txt

PERO ANTES, asegúrate de conocer los tres primeros comandos a continuación!!!

Comandos útiles al visualizar el archivo con el comando anterior (llamado 'less'): 
q              -- salir
/error<ENTER>  -- buscar la palabra 'error'
n              -- buscar la siguiente ocurrencia
g              -- ir al principio del archivo
f              -- avanzar una página
b              -- retroceder una página
G              -- ir al final del archivo
2 Me gusta

Make sure the settings highlighted by Doctor are correctly filled and not empty.

For example: DISCOURSE_HOSTNAME: mydomain.com (note separator should be : not =)

You can check the syntax with an online YML validator: http://www.yamllint.com/

that file was not modified at all … it’s same as it was when things were working :frowning:
I’ve checked line by line, no errors …

Here you have:

## this is the all-in-one, standalone Discourse Docker container template
##
## After making changes to this file, you MUST rebuild
## /var/discourse/launcher rebuild app
##
## BE *VERY* CAREFUL WHEN EDITING!
## YAML FILES ARE SUPER SUPER SENSITIVE TO MISTAKES IN WHITESPACE OR ALIGNMENT!
## visit http://www.yamllint.com/ to validate this file as needed

templates:
  - "templates/postgres.template.yml"
  - "templates/redis.template.yml"
  - "templates/web.template.yml"
  - "templates/web.ratelimited.template.yml"
  - "templates/web.socketed.template.yml"
## Uncomment these two lines if you wish to add Lets Encrypt (https)
  - "templates/web.ssl.template.yml"
  - "templates/web.letsencrypt.ssl.template.yml"

## which TCP/IP ports should this container expose?
## If you want Discourse to share a port with another webserver like Apache or nginx,
## see https://meta.discourse.org/t/17247 for details
#expose:#
  - "80:80"   # http
  - "443:443" # https

params:
  db_default_text_search_config: "pg_catalog.english"

  ## Set db_shared_buffers to a max of 25% of the total memory.
  ## will be set automatically by bootstrap based on detected RAM, or you can override
  db_shared_buffers: "256MB"

  ## can improve sorting performance, but adds memory usage per-connection
  #db_work_mem: "40MB"

  ## Which Git revision should this container use? (default: tests-passed)
  #version: tests-passed

env:
  LANG: en_US.UTF-8
  # DISCOURSE_DEFAULT_LOCALE: en

  ## How many concurrent web requests are supported? Depends on memory and CPU cores.
  ## will be set automatically by bootstrap based on detected CPUs, or you can override
  UNICORN_WORKERS: 4

  ## TODO: The domain name this Discourse instance will respond to
  ## Required. Discourse will not work with a bare IP number.
  DISCOURSE_HOSTNAME: 'XXXXXXXXXXXX'

  ## Uncomment if you want the container to be started with the same
  ## hostname (-h option) as specified above (default "$hostname-$config")
  #DOCKER_USE_HOSTNAME: true

  ## TODO: List of comma delimited emails that will be made admin and developer
  ## on initial signup example 'user1@example.com,user2@example.com'
  DISCOURSE_DEVELOPER_EMAILS: 'XXXXXXXXXXXX'

  ## TODO: The SMTP mail server used to validate new accounts and send notifications
  # SMTP ADDRESS, username, and password are required
  # WARNING the char '#' in SMTP password can cause problems!
  DISCOURSE_SMTP_ADDRESS: XXXXXXXXXXXX
  DISCOURSE_SMTP_PORT: 587
  DISCOURSE_SMTP_USER_NAME: XXXXXXXXXXXX
  DISCOURSE_SMTP_PASSWORD: "XXXXXXXXXXXX"
  DISCOURSE_SMTP_ENABLE_START_TLS: false           # (optional, default true)

  ## If you added the Lets Encrypt template, uncomment below to get a free SSL certificate
  LETSENCRYPT_ACCOUNT_EMAIL: XXXXXXXXXXXX

  ## The http or https CDN address for this Discourse instance (configured to pull)
  ## see https://meta.discourse.org/t/14857 for details
  #DISCOURSE_CDN_URL: https://discourse-cdn.example.com

## The Docker container is stateless; all data is stored in /shared
volumes:
  - volume:
      host: /var/discourse/shared/standalone
      guest: /shared
  - volume:
      host: /var/discourse/shared/standalone/log/var-log
      guest: /var/log

## Plugins go here
## see https://meta.discourse.org/t/19157 for details
hooks:
  after_code:
    - exec:
        cd: $home/plugins
        cmd:
          - git clone https://github.com/discourse/docker_manager.git
          - git clone https://github.com/discourse/discourse-plugin-linkedin-auth.git
          - git clone https://github.com/discourse/discourse-oauth2-basic.git
          - git clone https://github.com/discourse/discourse-solved.git
          - git clone https://github.com/discourse/discourse-voting.git
          - git clone https://github.com/discourse/discourse-assign.git
          - git clone https://github.com/discourse/discourse-staff-notes.git
          - git clone https://github.com/discourse/discourse-checklist.git
          - git clone https://github.com/discourse/discourse-social-share.git
          - git clone https://github.com/rcfox/Discourse-LinkedIn-Sharing-Button.git
          - git clone https://github.com/BeXcellent/discourse-allowiframe.git

## Any custom commands to run after building
run:
  - exec: echo "Beginning of custom commands"
  ## If you want to set the 'From' email address for your first registration, uncomment and change:
  ## After getting the first signup email, re-comment the line. It only needs to run once.
  #- exec: rails r "SiteSetting.notification_email='info@unconfigured.discourse.org'"
  - exec: echo "End of custom commands"

Try with deleting the ' characters in hostname and developper emails

'XXXXXXXXXXXX'

¿Por qué está comentando el comando?

#expose:#
  - "80:80"   # http
  - "443:443" # https

Esto explica la salida del error:

cat: 80:80: No existe el archivo o el directorio
cat: 443:443: No existe el archivo o el directorio
5 Me gusta

¡Pero necesito que esas líneas estén ahí!

Lee lo que dije. Has añadido un #.

1 me gusta

Debería ser:

expose:
  - "80:80"   # http
  - "443:443" # https
6 Me gusta

No lo hice tan fácil porque alguien tiene que pensar cómo podrían ocurrir tales errores si esto es cierto.

2 Me gusta