<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>42313</bug_id>
          
          <creation_ts>2022-04-01 14:53:40 +0300</creation_ts>
          <short_desc>duplicate listen 127.0.0.1:80 в конфигурации по умолчанию</short_desc>
          <delta_ts>2023-05-24 00:18:53 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>nginx</component>
          <version>unstable</version>
          <rep_platform>x86_64</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P5</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="manowar@altlinux.org">manowar</reporter>
          <assigned_to name="Anton Farygin">rider</assigned_to>
          <cc>placeholder</cc>
    
    <cc>rider</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>209074</commentid>
    <comment_count>0</comment_count>
    <who name="manowar@altlinux.org">manowar</who>
    <bug_when>2022-04-01 14:53:40 +0300</bug_when>
    <thetext>При включении сайта по умолчанию сервер отказывается работать с сообщением:

  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/

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

  &quot;localhost on modern OSes resolves to 127.0.0.1 and ::1 and using hostname instead of IP address gives you this error&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>226300</commentid>
    <comment_count>1</comment_count>
    <who name="Anton Farygin">rider</who>
    <bug_when>2023-05-24 00:18:53 +0300</bug_when>
    <thetext>исправлено в 1.24.0-alt1</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>