Using environment variables instead of hardcoding the ports

Please review!