knote-java
knote-java copied to clipboard
mongodb ConnectException: in mac with branch 2 (dockerization example)
com.mongodb.MongoSocketOpenException: Exception opening socket Caused by: java.net.ConnectException: Connection refused (Connection refused)
@srinivasbellarichenna did you by any chance get this working?
@srinivasbellarichenna I figured it out. One needs to update their applications.properties
file to use EnVars i.e. spring.data.mongodb.uri=${MONGO_URL:mongodb://localhost:27017/dev}
You then need to:
- do a new maven clean and install
- re build the knote-java docker image again. Use the no cache flag i.e.
docker build --no-cache -t knote-java .
Hopefully this should fix your issue. If so please feel free to close this issue :)