Support IPv6

Open
#12 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
38/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
laravel, php

Research direction

Start with app/Factory.php around line 204 and app/Commands/ServeCommand.php around line 51, then reproduce the reported command on Debian. Trace how the IPv6 address is passed to React SocketServer and verify the server can listen successfully on IPv6 port 8080 without the shown getaddrinfo error.

Written by the indexing model from the issue text.

Description

root@debian13-test:~/expose# php ./expose-server serve my-domain.com ::
[2026-02-04 17:16:37] development.ERROR: Failed to listen on "tcp://:::8080": php_network_getaddresses: getaddrinfo for  failed: Name or service not known {"exception":"[object] (RuntimeException(code: 0): Failed to listen on \"tcp://:::8080\": php_network_getaddresses: getaddrinfo for  failed: Name or service not known at /root/expose/vendor/react/socket/src/TcpServer.php:188)
[stacktrace]
#0 /root/expose/vendor/react/socket/src/SocketServer.php(65): React\\Socket\\TcpServer->__construct()
#1 /root/expose/app/Factory.php(204): React\\Socket\\SocketServer->__construct()
#2 /root/expose/app/Commands/ServeCommand.php(51): Expose\\Server\\Factory->createServer()
#3 /root/expose/vendor/illuminate/container/BoundMethod.php(36): Expose\\Server\\Commands\\ServeCommand->handle()
#4 /root/expose/vendor/illuminate/container/Util.php(43): Illuminate\\Container\\BoundMethod::{closure:Illuminate\\Container\\BoundMethod::call():35}()
#5 /root/expose/vendor/illuminate/container/BoundMethod.php(95): Illuminate\\Container\\Util::unwrapIfClosure()
#6 /root/expose/vendor/illuminate/container/BoundMethod.php(35): Illuminate\\Container\\BoundMethod::callBoundMethod()
#7 /root/expose/vendor/illuminate/container/Container.php(696): Illuminate\\Container\\BoundMethod::call()
#8 /root/expose/vendor/illuminate/console/Command.php(213): Illuminate\\Container\\Container->call()
#9 /root/expose/vendor/symfony/console/Command/Command.php(341): Illuminate\\Console\\Command->execute()
#10 /root/expose/vendor/illuminate/console/Command.php(182): Symfony\\Component\\Console\\Command\\Command->run()
#11 /root/expose/vendor/symfony/console/Application.php(1102): Illuminate\\Console\\Command->run()
#12 /root/expose/vendor/symfony/console/Application.php(356): Symfony\\Component\\Console\\Application->doRunCommand()
#13 /root/expose/vendor/symfony/console/Application.php(195): Symfony\\Component\\Console\\Application->doRun()
#14 /root/expose/vendor/laravel-zero/foundation/src/Illuminate/Foundation/Console/Kernel.php(198): Symfony\\Component\\Console\\Application->run()
#15 /root/expose/vendor/laravel-zero/framework/src/Kernel.php(111): Illuminate\\Foundation\\Console\\Kernel->handle()
#16 /root/expose/expose-server(35): LaravelZero\\Framework\\Kernel->handle()
#17 {main}
"}

   RuntimeException

  Failed to listen on "tcp://:::8080": php_network_getaddresses: getaddrinfo for  failed: Name or service not known

  at vendor/react/socket/src/TcpServer.php:188
    184▕                 // @link https://3v4l.org/3qOBl
    185▕                 $errno = SocketServer::errno($errstr);
    186▕             }
    187▕
  ➜ 188▕             throw new \RuntimeException(
    189▕                 'Failed to listen on "' . $uri . '": ' . $errstr . SocketServer::errconst($errno),
    190▕                 $errno
    191▕             );
    192▕         }

      +1 vendor frames

  2   app/Factory.php:204
      React\Socket\SocketServer::__construct()

  3   app/Commands/ServeCommand.php:51
      Expose\Server\Factory::createServer()

Expose server running on port 8080.
Dominant language
PHP
Stars
25
Forks
25
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from exposedev/server

All issues in exposedev/server

Similar issues

More PHP issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.