spatie/http-status-check
最新稳定版本:4.0.0
Composer 安装命令:
composer require spatie/http-status-check
包简介
CLI tool to crawl a website and check HTTP status code
README 文档
README
This repository provides a tool to check the HTTP status code of every link on a given website.
Support us
We invest a lot of resources into creating best in class open source packages. You can support us by buying one of our paid products.
We highly appreciate you sending us a postcard from your hometown, mentioning which of our package(s) you are using. You'll find our address on our contact page. We publish all received postcards on our virtual postcard wall.
Installation
This package can be installed via Composer:
composer global require spatie/http-status-check
Usage
This tool will scan all links on a given website:
http-status-check scan https://example.com
It outputs a line per link found. Here's an example on Laracast website scan:
When the crawling process is finished a summary will be shown.
By default the crawler uses 10 concurrent connections to speed up the crawling process. You can change that number by passing a different value to the --concurrency option:
http-status-check scan https://example.com --concurrency=20
You can also write all urls that gave a non-2xx or non-3xx response to a file:
http-status-check scan https://example.com --output=log.txt
When the crawler finds a link to an external website it will by default crawl that link as well. If you don't want the crawler to crawl such external urls use the --dont-crawl-external-links option:
http-status-check scan https://example.com --dont-crawl-external-links
By default, requests timeout after 10 seconds. You can change this by passing the number of seconds to the --timeout option:
http-status-check scan https://example.com --timeout=30
By default, the crawler will respect robots data. You can ignore them though with the --ignore-robots option:
http-status-check scan https://example.com --ignore-robots
If your site requires a basic authentification, you can use the --auth option:
http-status-check scan https://example.com --auth=username:password
Testing
To run the tests, first make sure you have Node.js installed. Then start the included node based server in a separate terminal window:
cd tests/server
npm install
node server.js
With the server running, you can start testing:
vendor/bin/phpunit
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security
If you've found a bug regarding security please mail security@spatie.be instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.
spatie/http-status-check 适用场景与选型建议
spatie/http-status-check 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 48.22k 次下载、GitHub Stars 达 598, 最近一次更新时间为 2015 年 11 月 02 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「http」 「check」 「crawler」 「status」 「spatie」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 spatie/http-status-check 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 spatie/http-status-check 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 spatie/http-status-check 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
A lightweight, dependency free PHP class that acts as wrapper for Crawlbase API
repository php library
A Symfony bundle for chameleon-system/sanitycheck
This Extension integrates a credit check and more made by the LEONEX Risk Management Platform into your order process. Extensive configuration and evaluation options is provided in the Platform
SoftWax Health Check Bundle for Symfony framework
统计信息
- 总下载量: 48.22k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 601
- 点击次数: 29
- 依赖项目数: 0
- 推荐数: 1
其他信息
- 授权协议: MIT
- 更新时间: 2015-11-02