openmhealth / omh-dsu-ri

An application for storing mobile health data and authorizing access to it.
http://www.openmhealth.org/documentation/#/store-data/storage-overview
Apache License 2.0
39 stars 32 forks source link

docker-compose is not working #21

Open babbayo opened 3 years ago

babbayo commented 3 years ago

when i tried docker-compose, postgresql has something wrong.

> docker-compose -f docker-compose.yml up -d
Creating omh-dsu-ri_mongo_1    ... done
Creating omh-dsu-ri_postgres_1 ... done
Creating omh-dsu-ri_authorizationserver_1 ...
Creating omh-dsu-ri_resourceserver_1      ... error

ERROR: for omh-dsu-ri_resourceserver_1  Cannot start service resourceserver: Can
Creating omh-dsu-ri_authorizationserver_1 ... error
rceserver_1/omh-dsu-ri_postgres_1

ERROR: for omh-dsu-ri_authorizationserver_1  Cannot start service authorizationserver: Cannot link to a non running container: /omh-dsu-ri_postgres_1 AS /omh-dsu-ri_authorizationserver_1/omh-dsu-ri_postgres_1

ERROR: for resourceserver  Cannot start service resourceserver: Cannot link to a non running container: /omh-dsu-ri_postgres_1 AS /omh-dsu-ri_resourceserver_1/omh-dsu-ri_postgres_1

ERROR: for authorizationserver  Cannot start service authorizationserver: Cannot link to a non running container: /omh-dsu-ri_postgres_1 AS /omh-dsu-ri_authorizationserver_1/omh-dsu-ri_postgres_1
ERROR: Encountered errors while bringing up the project.

so i changed docker-compose like this, and it works good.

postgres:
  environment:
    - POSTGRES_HOST_AUTH_METHOD=trust
  image: postgres:latest
  ports:
    - "5432:5432"