SKIP_CONNECTION_TEST 在 install-discourse 脚本上无效

我已经尝试了所有我能想到的方法,但都没有奏效,所以我只能推断这是一个错误。

我尝试过的方法:

  • SKIP_CONNECTION_TEST=1 ./install-discourse
  • export SKIP_CONNECTION_TEST=1; ./install-discourse
  • 注释掉我本地 discourse-setup 副本中的那一行

但它仍然抱怨没有端口 443(这不是问题,因为我在反向代理后面):

root@discourse:~/discourse_docker# ./install-discourse 

Discourse One-Line Installer

→ Docker is already installed
==> Setting up Discourse Docker
→ Existing installation found at /var/discourse
→ Updating repository...
HEAD is now at 2ad96ec DEV: Remove ruby 3.4 build step (#1042)
→ Repository ready at /var/discourse
==> Starting Discourse Setup Wizard

→ Checking for setup wizard image updates...
release: Pulling from discourse/setup-wizard
Digest: sha256:7ca57ab89b6659bea41f78ed667876ef8f00d80f4addfea9ec7907f1bf5ad544
Status: Image is up to date for discourse/setup-wizard:release
docker.io/discourse/setup-wizard:release
→ Starting Discourse Setup Wizard...


 ___  _
|   \_(_)___ __ ___ _  _ _ _ ___ ___
| |) | (_-< / _/ _ \ || | '_(_-< / -_)
|___/|_/__/\__\___/\_,_|_| /__/\___|
                       Setup Wizard


→ This wizard will help you configure your Discourse installation.
→ Press Ctrl+C at any time to cancel.

── System Checks ──

[1/5] Verifying system requirements
✓ Running as root
✓ Docker is available
✓ Memory: 33GB, CPU: 112 cores

── Configuration ──

[2/5] Preparing configuration
✓ Ports 80 and 443 are free for use
→ Creating new configuration...
→ Creating new configuration from template...

── Site Settings ──

[3/5] Enter your site details

Email address for admin account(s)?
[redacted]@proton.me▌

Do you have a domain name for your Discourse?
▸ Yes      No

Hostname for your Discourse?
discourse.pyxfluff.dev▌

Configure SMTP for sending emails? (Requires SMTP credentials)
  Yes    ▸ No


── Review Configuration ──


╭────────────────────────────────────────────╮
│                                            │
│  Hostname       discourse.pyxfluff.dev     │
│  Admin Email    [redacted]@proton.me        │
│  SMTP           (not configured)           │
│  Let's Encrypt  Enabled                    │
│                                            │
╰────────────────────────────────────────────╯


Does this look right?
▸ Yes      No
→ Found 33GB of memory and 112 CPU cores
→ Setting db_shared_buffers = 4096MB
→ Setting UNICORN_WORKERS = 8

── Network Validation ──

[4/5] Verifying domain configuration
→ Checking your domain name...
⚠ Port 443 of this computer does not appear to be accessible using hostname: discourse.pyxfluff.dev

✓ A connection to port 80 succeeds!
This suggests that your DNS settings are correct,
but something is keeping traffic to port 443 from getting to your server.
Check your networking configuration to see that connections to port 443 are allowed.

The first thing to do is confirm that discourse.pyxfluff.dev resolves to the IP address of this server.
You usually do this at the same place you purchased the domain.

If you are sure that the IP address resolves correctly, it could be a firewall issue.
A web search for "open ports YOUR CLOUD SERVICE" might help.

This tool is designed only for the most standard installations. If you cannot resolve
the issue above, you will need to edit containers/app.yml yourself and then type:

    ./launcher rebuild app


✗ DNS verification failed for discourse.pyxfluff.dev
root@discourse:~/discourse_docker# 

我可以确认环境变量已正确设置:

我在这里也无能为力了,看起来我对这个脚本无计可施,这很遗憾,因为我不想使用 SMTP。看起来它只是为云托管而设计的(在云托管中,在一台 IP 上运行多个服务不是什么大问题)。

1 个赞

我以前用过 skip-connection-test,但我认为它是一个用于命令的开关,如下所示

./install-discourse --skip-connection-test

我不确定确切的语法,但我记得在文档中很难找到它。

2 个赞

谢谢,这对我现在有效。我仍然觉得环境变量不起作用很奇怪/是意外的,这可能是一个问题,但我会让工作人员来决定。

2 个赞

我一直在想为什么它拒绝连接,而且看起来脚本甚至没有尝试配置站点。