eiriksm/wait-for-listen
最新稳定版本:1.0.1
Composer 安装命令:
composer require eiriksm/wait-for-listen
包简介
Waits until a port is listening.
README 文档
README
Installation
composer require eiriksm/wait-for-listen
...or probably you want this as a dev requirement:
composer require eiriksm/wait-for-listen --dev
Usage
This package is useful to use in CI setups before your tests assume a service has started.
So instead of this:
- ./some-slow-starting-task-that-exposes-port 8000 &
- sleep 5
- composer test
You can now use this:
- ./some-slow-starting-task-that-exposes-port 8000 &
- ./vendor/bin/wait-for-listen 8000
Configuration
wait-for-listen has 3 options. Port, host and timeout.
They are specified like this:
./vendor/bin/wait-for-listen <port> [host] [timeout]
Port (required)
Specify a port to wait for.
Host (optional)
Specify an optional host. The default is 127.0.0.1.
Timeout (optional)
Specify a timeout. The default is 10.
Licence
WTFPL.
统计信息
- 总下载量: 118.66k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-2.0
- 更新时间: 2017-07-10