2 years ago
I deleted my postgress database a week ago and reinstalled it only to find yesterday that the egress usage had gone from almost nothing to $18.
I have since deleted the database and reinstalled it again and now it's gone down to around a third of that. Any idea how to get it back to almost nothing again? I have no idea what has caused it to jump.
22 Replies
2 years ago
are you connecting to it over the public network?
2 years ago
you are using the public network then, thus you are subjecting yourself to egress fees
2 years ago
connect to the database via the private network, there is no network costs for service to service communication over the private network
2 years ago
correct
2 years ago
please provide error messages
django.db.utils.OperationalError: could not translate host name "postgres.railway.internal" to address: Name or service not known
2 years ago
does your service in question have a volume?
2 years ago
then you will need to prefix the start command with a 3 second sleep
2 years ago
sleep 3; python manage.py migrate && python manage.py collectstatic --no-input && gunicorn jobsite.wsgi
2 years ago
no problem!
I'll just have to keep an eye on the costs and see if they come back down now
2 years ago
there is no network costs for service to service communication over the private network, so if your egress costs go up, it's something else