Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Will it break the existing mirror if i migrate to this ? #9

Open
varunsridharan opened this issue Nov 23, 2020 · 7 comments
Open

Will it break the existing mirror if i migrate to this ? #9

varunsridharan opened this issue Nov 23, 2020 · 7 comments

Comments

@varunsridharan
Copy link

Hi There

I am currently running a mirror in india (https://packagist.in/) and it uses https://github.com/webysther/packagist-mirror

and it runs mirror for V1. but i want to support V1 & V2

so i am planing on using this script. i can create my own home page but will this break existing users if i migrate to this script ?

@Seldaek
Copy link
Member

Seldaek commented Nov 23, 2020

No it should not break anything.. As long as you let it sync up before putting it in prod. The current version of webysther's mirror is actually breaking things for composer 2 users.

@varunsridharan
Copy link
Author

@Seldaek will this works with apache server or it requires nginx ? because webysther code requires nginx

@Seldaek
Copy link
Member

Seldaek commented Nov 23, 2020

It should work with apache I think, but I haven't tested it.. I added web server requirements now in the readme: https://github.com/composer/mirror/blob/master/README.md#requirements

@varunsridharan
Copy link
Author

@Seldaek thanks i will check . if any issues will get back to you

@varunsridharan
Copy link
Author

@Seldaek

i tried to run this inside cPanel and this script keeps getting errors

[24-Nov-2020 02:05:43 UTC] PHP Fatal error:  Uncaught Symfony\Component\HttpClient\Exception\TransportException: Failure when receiving data from the peer for "https://repo.packagist.org/p/religis/utils$b060cc2de65557193dc7ae14ad74a4a9220c7e02b2395ccf884799cdba1c67ee.json". in /home/packagist/public_html/mirror/vendor/symfony/http-client/Response/CurlResponse.php:297
Stack trace:
#0 /home/packagist/public_html/mirror/vendor/symfony/http-client/Response/ResponseTrait.php(326): Symfony\Component\HttpClient\Response\CurlResponse::perform(Object(Symfony\Component\HttpClient\Internal\CurlClientState), Array)
#1 [internal function]: Symfony\Component\HttpClient\Response\CurlResponse::stream(Array, NULL)
#2 /home/packagist/public_html/mirror/vendor/symfony/http-client/Response/ResponseStream.php(47): Generator->rewind()
#3 /home/packagist/public_html/mirror/mirror.php(421): Symfony\Component\HttpClient\Response\ResponseStream->rewind()
#4 /home/packagist/public_html/mirror/mirror.php(725): Mirror->sync()
#5 {main}

Next Symfony\Component\HttpClient\Exception\T in /home/packagist/public_html/mirror/vendor/symfony/http-client/Chunk/ErrorChunk.php on line 65
[24-Nov-2020 02:10:15 UTC] PHP Fatal error:  Uncaught Symfony\Component\HttpClient\Exception\TransportException: Couldn't connect to server for "https://repo.packagist.org/p/sskaje/ipcalc$72514e9873ec7afecf8788fd62c05a2a6b7ceafe7c01cd484fadfbd08786a637.json". in /home/packagist/public_html/mirror/vendor/symfony/http-client/Response/CurlResponse.php:297
Stack trace:
#0 /home/packagist/public_html/mirror/vendor/symfony/http-client/Response/ResponseTrait.php(326): Symfony\Component\HttpClient\Response\CurlResponse::perform(Object(Symfony\Component\HttpClient\Internal\CurlClientState), Array)
#1 [internal function]: Symfony\Component\HttpClient\Response\CurlResponse::stream(Array, NULL)
#2 /home/packagist/public_html/mirror/vendor/symfony/http-client/Response/ResponseStream.php(47): Generator->rewind()
#3 /home/packagist/public_html/mirror/mirror.php(421): Symfony\Component\HttpClient\Response\ResponseStream->rewind()
#4 /home/packagist/public_html/mirror/mirror.php(725): Mirror->sync()
#5 {main}

Next Symfony\Component\HttpClient\Exception\TransportExcepti in /home/packagist/public_html/mirror/vendor/symfony/http-client/Chunk/ErrorChunk.php on line 65

I tried increasing execution time & memory but nothing works. !!

@Seldaek
Copy link
Member

Seldaek commented Nov 24, 2020

Yeah sorry but I have no idea what might be causing this. Looks like poor network connectivity to me.

@peter279k
Copy link

I have no ideas and experiences about running this mirror script inside cPanel.

But it's worked for me on a VPS (virtual private server) with Ubuntu 18.04.

Maybe I think it's about the temporary network connectivity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants