certbotが追加されたVirtualHostを認識できません。

certbotが追加されたVirtualHostを認識できません。

nextcloud(raspiのArcharm)を実行しているhttpサーバーの証明書を取得するためにcertbotを使用しようとしています。私が実行すると、$ sudo certbot --apache次のようになります。

$ sudo certbot --apache      
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator apache, Installer apache
No names were found in your configuration files. Please enter in your domain
name(s) (comma and/or space separated)  (Enter 'c' to cancel): 

その後、私のドメインを入力すると、次のexample.duckdns.org情報が得られます。

Obtaining a new certificate
Performing the following challenges:
http-01 challenge for example.duckdns.org
Cleaning up challenges
Unable to find a virtual host listening on port 80 which is currently needed for Certbot to prove to the CA that you control your domain. Please add a virtual host for port 80.

example_duckdns.conf私はこのような状況に直面していますが/etc/httpd/conf/extra

<Directory /var/www/html/nextcloud>
    Require all granted
</Directory>

<VirtualHost *:80>
    DocumentRoot "/var/www/html/nextcloud"
    ServerName example.duckdns.org
    ServerAlias example.duckdns.org
    ServerAdmin [email protected]
    ErrorLog "/var/log/httpd/error_log_example_duckdns_org"
    CustomLog "/var/log/httpd/access_log_example_duckdns_org" combined
</VirtualHost>

私は得る:

$ apachectl configtest        
Syntax OK

私に何の問題もあるのか?

使用:Apache/2.4.43

ベストアンサー1

もちろん、あなたは/etc/httpd/conf/extra正確に見えますが、デフォルトのApache設定ファイル(またはここに含まれるすべてのファイル)に似たInclude /etc/httpd/conf/extraものがありますかIncludeOptional /etc/httpd/conf/*

おすすめ記事