Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/spekulatius/faasd-phpscraper
openfaas/faasd wrapper for PHPScraper
https://github.com/spekulatius/faasd-phpscraper
faasd function-as-a-service openfaas php-faas phpscraper
Last synced: about 1 month ago
JSON representation
openfaas/faasd wrapper for PHPScraper
- Host: GitHub
- URL: https://github.com/spekulatius/faasd-phpscraper
- Owner: spekulatius
- License: gpl-3.0
- Created: 2020-12-03T21:07:27.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2023-05-28T10:43:17.000Z (over 1 year ago)
- Last Synced: 2024-11-04T21:37:04.573Z (about 2 months ago)
- Topics: faasd, function-as-a-service, openfaas, php-faas, phpscraper
- Language: PHP
- Homepage: https://phpscraper.de
- Size: 25.4 KB
- Stars: 6
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE.md
Awesome Lists containing this project
README
# PHP Scraper as a Function
A simple [OpenFaaS](https://github.com/openfaas/faas)/[faasd](https://github.com/openfaas/faasd) wrapper around [PHP Scraper](https://github.com/spekulatius/PHPScraper). Essentially turning your scraper into a function.
## Usage
1. Fork and clone the fork.
2. Adjust the `stack.yml` file with your docker hub name.
3. Change the handler to your needs.
4. `faas-cli up --gateway http://faasd.somewhere.com:8080`.## How to generate the secret?
1. Create a secret:
```bash
echo $(head -c 16 /dev/urandom | shasum | cut -d "-" -f1) > token.txt
```2. Store it on the server:
```bash
faas-cli secret create phpscraper-token --from-file token.txt --gateway http://yourfaasd.somewhere.com:8080
```3. Deploy as usual:
```bash
faas-cli up --gateway http://yourfaasd.somewhere.com:8080
```## How to develop with PHPScraper?
For more information on core functionality of PHPScraper check the [documentation](https://phpscraper.de). The tests and examples can also help understanding it better.