Trying to get Postgres working on a uby-rails-postgres-nginx-unicorn-512mb-nyc1-01 droplet
I am trying to get postgres working on my droplet.
If I do a port scan for the ip of 5432, it says the port is closed. If I try to access with PGAdminIII, I get an error of 'server doesn't listen'
If I do a psql \conninfo I get
You are connected to database "rails" as user "rails" via socket in "/var/run/postgresql" at port "5432".
I am able to connect with psql and create a test table
rails=> create table test (test varchar (10) ); CREATE TABLE rails=> /dt rails-> \d List of relations Schema | Name | Type | Owner --------+------+-------+------- public | test | table | rails (1 row) rails->
I think the problem could be in my database.yml. Is this the correct code for production?
production: <<: *default database: rails username: rails password: <%= ENV['APP_DATABASE_PASSWORD'] %>
I'd appreciate any help in getting pg working