2017 © Pedro Peláez
 

symfony-bundle http-client-bundle

Advanced http proxying

image

glooby/http-client-bundle

Advanced http proxying

  • Wednesday, March 29, 2017
  • by kilhage
  • Repository
  • 2 Watchers
  • 1 Stars
  • 233 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 4 % Grown

The README.md

http-client-bundle

Requirements

  • PHP 5.6 or above
  • [Guzzle PHP Framework][guzzle] (included by composer)
  • Symfony 2.7 or above (including Symfony 3.x)

Installation

To install this bundle, run the command below and you will get the latest version by [Packagist][packagist]., (*1)

``` bash composer require glooby/http-client-bundle dev-master, (*2)


To use the newest (maybe unstable) version please add following into your composer.json: ``` json { "require": { "glooby/http-client-bundle": "dev-master" } }

Load bundle in AppKernel.php: ``` php, (*3)

public function registerBundles()
{
    $bundles = [
        ...
        new Glooby\HttpClientBundle\GloobyHttpClientBundle(),
        ...
    ];
}

## Configuration Configure in app/config/parameters.yml: #### single ``` yaml parameters: ... glooby.http.proxy: socks5://127.0.0.1:1080

file

``` yaml parameters: ... glooby.http.proxy: /etc/proxyfile, (*4)


$ cat /etc/proxy socks5://127.0.0.1:1080 Supports single/multiple lines #### multiple ``` yaml parameters: ... glooby.http.proxy: - http://127.0.0.1:1081 - socks5://127.0.0.1:1080 - socks4://127.0.0.1:1082

mix

``` yaml parameters: ... glooby.http.proxy: - socks5://127.0.0.1:1080 - socks5://john:doe@127.0.0.1:1081 - /etc/proxy1 - /etc/proxy2, (*5)


When providing multiple proxies a random one will be select each time creating a new client ## Usage ``` php $ip = $this->get('glooby.http.client')->get('http://api.ipify.org')->getBody();

Support

Supported proxy types

  • http
  • https
  • socks4
  • socks4a
  • socks5
  • socks5h

License

This bundle is released under the MIT license, (*6)

The Versions

29/03 2017

dev-master

9999999-dev

Advanced http proxying

  Sources   Download

MIT

The Requires

 

29/03 2017

0.1.1

0.1.1.0

Advanced http proxying

  Sources   Download

MIT

The Requires

 

22/03 2017

0.1.0

0.1.0.0

Advanced http proxying

  Sources   Download

MIT

The Requires