DDEV 项目使用 http 而不是 https 启动站点
DDEV Project starts up site with http instead of https
我在 MacBook 上 运行ning DDEV。 DDEV 曾在 https://projectname.ddev.site but now only starts up http://projectname.ddev.site 交付项目。
我不能确切地说出这种变化是什么时候发生的。我知道“mkcert 可能没有正确安装......”的通知,我确实按照安装建议进行了操作,但它没有改变。
我该怎么做才能使 ddev 运行 https?
Starting testproject...
mkcert may not be properly installed, we suggest installing it for trusted https support, `brew install mkcert nss`, `choco install -y mkcert`, etc. and then `mkcert -install`
The hostname testproject.ddev.site is not currently resolvable, trying to add it to the hosts file
ddev needs to add an entry to your hostfile.
It will require administrative privileges via the sudo command, so you may be required
to enter your password for sudo. ddev is about to issue the command:
sudo /usr/local/bin/ddev hostname testproject.ddev.site 127.0.0.1
Please enter your password if prompted.
Running Command=sudo /usr/local/bin/ddev hostname testproject.ddev.site 127.0.0.1
Password:
Creating volume "testproject-mariadb" with default driver
Building db
Building web
Creating ddev-testproject-db ... done
Creating ddev-testproject-dba ... done
Creating ddev-testproject-web ... done
Creating ddev-router ... done
Project type has no settings paths configured, so not creating settings file.
Successfully started testproject
Project can be reached at http://testproject.ddev.site http://127.0.0.1:32889
kais-MBP:testproject kai$ ```
.ddev/config.yaml
```name: testproject
type: php
docroot: ""
php_version: "7.3"
webserver_type: nginx-fpm
router_http_port: "80"
router_https_port: "443"
xdebug_enabled: false
additional_hostnames: []
additional_fqdns: []
mariadb_version: "10.2"
mysql_version: ""
provider: default
use_dns_when_possible: true
composer_version: ""
您需要 运行 mkcert -install
才能使 https 工作,ddev 会检测您是否已这样做。所以 ddev poweroff
和 mkcert -install
和 ddev start
你应该会看到受信任的 https URL。
如果不行,请尝试使用 ddev poweroff && mkcert -uninstall && sudo rm -rf "$(mkcert -CAROOT)" && mkcert -install
完全删除 mkcert CA - 完全卸载并重新安装 mkcert。
我在 MacBook 上 运行ning DDEV。 DDEV 曾在 https://projectname.ddev.site but now only starts up http://projectname.ddev.site 交付项目。 我不能确切地说出这种变化是什么时候发生的。我知道“mkcert 可能没有正确安装......”的通知,我确实按照安装建议进行了操作,但它没有改变。 我该怎么做才能使 ddev 运行 https?
Starting testproject...
mkcert may not be properly installed, we suggest installing it for trusted https support, `brew install mkcert nss`, `choco install -y mkcert`, etc. and then `mkcert -install`
The hostname testproject.ddev.site is not currently resolvable, trying to add it to the hosts file
ddev needs to add an entry to your hostfile.
It will require administrative privileges via the sudo command, so you may be required
to enter your password for sudo. ddev is about to issue the command:
sudo /usr/local/bin/ddev hostname testproject.ddev.site 127.0.0.1
Please enter your password if prompted.
Running Command=sudo /usr/local/bin/ddev hostname testproject.ddev.site 127.0.0.1
Password:
Creating volume "testproject-mariadb" with default driver
Building db
Building web
Creating ddev-testproject-db ... done
Creating ddev-testproject-dba ... done
Creating ddev-testproject-web ... done
Creating ddev-router ... done
Project type has no settings paths configured, so not creating settings file.
Successfully started testproject
Project can be reached at http://testproject.ddev.site http://127.0.0.1:32889
kais-MBP:testproject kai$ ```
.ddev/config.yaml
```name: testproject
type: php
docroot: ""
php_version: "7.3"
webserver_type: nginx-fpm
router_http_port: "80"
router_https_port: "443"
xdebug_enabled: false
additional_hostnames: []
additional_fqdns: []
mariadb_version: "10.2"
mysql_version: ""
provider: default
use_dns_when_possible: true
composer_version: ""
您需要 运行 mkcert -install
才能使 https 工作,ddev 会检测您是否已这样做。所以 ddev poweroff
和 mkcert -install
和 ddev start
你应该会看到受信任的 https URL。
如果不行,请尝试使用 ddev poweroff && mkcert -uninstall && sudo rm -rf "$(mkcert -CAROOT)" && mkcert -install
完全删除 mkcert CA - 完全卸载并重新安装 mkcert。