Bug 42313 - duplicate listen 127.0.0.1:80 в конфигурации по умолчанию
Summary: duplicate listen 127.0.0.1:80 в конфигурации по умолчанию
Status: CLOSED FIXED
Alias: None
Product: Sisyphus
Classification: Development
Component: nginx (show other bugs)
Version: unstable
Hardware: x86_64 Linux
: P5 normal
Assignee: Anton Farygin
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-04-01 14:53 MSK by manowar@altlinux.org
Modified: 2023-05-24 00:18 MSK (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description manowar@altlinux.org 2022-04-01 14:53:40 MSK
При включении сайта по умолчанию сервер отказывается работать с сообщением:

  nginx: [emerg] a duplicate listen 127.0.0.1:80 in /etc/nginx/sites-enabled.d/default.conf:7

Решение состоит в замене строки

  listen localhost:80;

просто на

  listen 80;

Подробности можно прочитать тут: https://talk.plesk.com/threads/nginx-suddenly-gives-a-configuration-error-after-upgrade.353275/

Главное, по-моему, вот в этом:

  "localhost on modern OSes resolves to 127.0.0.1 and ::1 and using hostname instead of IP address gives you this error"
Comment 1 Anton Farygin 2023-05-24 00:18:53 MSK
исправлено в 1.24.0-alt1