Can you access any other files or directories on that domain? Like can you visit https://repo.packagist.org/packages.json? It should just be a simple 404 page:
Maybe somehow that domain made it in your hosts
file and is redirecting to somewhere strange. Take a look in /etc/hosts
with a text editor and if that domain is present, just delete the line:
sudo nano /etc/hosts