mdouchement / standardnotes

Dockerization of Standard File server. Used for running your own Standard Notes server
MIT License
11 stars 2 forks source link

Possible change to database name? #1

Open jmhammond opened 5 years ago

jmhammond commented 5 years ago

When attempting to run as directed, I received this error on the database step:

<Mysql2::Error: Can't connect to MySQL server on 'database' (115)>

Couldn't create database for {"adapter"=>"mysql2", "encoding"=>"utf8", "pool"=>5, "username"=>"root", "password"=>"root", "database"=>"standardfile", "host"=>"database", "port"=>nil}, {:charset=>"utf8"} (If you set the charset manually, make sure you have a matching collation) Created database 'standardfile'

I made the following change to docker-compose.yml Line 25, from DB_HOST: database to DB_HOST: db, and it ran without error.

mdouchement commented 5 years ago

It's a bit odd. The following lines: https://github.com/mdouchement/standardnotes/blob/2a26d30848d6b398a5ca80da719c522e04e269c5/docker-compose.yml#L23-L24

Defines the database service as database host (in /etc/hosts) inside the standardfile service.

Anyway I've made some slight changes that will improve the boot of the docker-compose stack (https://github.com/mdouchement/standardnotes/commit/2a26d30848d6b398a5ca80da719c522e04e269c5).

I didn't encounter any issue during my tests.

PS: I've opened the following issue https://github.com/standardfile/ruby-server/issues/81 because I'm using my own implementation of standardfile. (aka I'm not keeping this repository up-to-date anymore)

jmhammond commented 5 years ago

Okay, thanks for letting me know about this.

On Sat, Apr 20, 2019 at 3:22 PM mdouchement notifications@github.com wrote:

It's a bit odd. The following lines:

https://github.com/mdouchement/standardnotes/blob/2a26d30848d6b398a5ca80da719c522e04e269c5/docker-compose.yml#L23-L24

Defines the database service as database host (in /etc/hosts) inside the standardfile service.

Anyway I've made some slight changes that will improve the boot of the docker-compose stack (2a26d30 https://github.com/mdouchement/standardnotes/commit/2a26d30848d6b398a5ca80da719c522e04e269c5 ).

I didn't encounter any issue during my tests.

PS: I've opened the following issue standardfile/ruby-server#81 https://github.com/standardfile/ruby-server/issues/81 because I'm using my own implementation of standardfile https://github.com/mdouchement/standardfile. (aka I'm not keeping this repository up-to-date anymore)

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/mdouchement/standardnotes/issues/1#issuecomment-485164565, or mute the thread https://github.com/notifications/unsubscribe-auth/AAAURKYIP4R4KVH5MB2VYILPRN3SBANCNFSM4HHJ5DKA .