Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MS SQL Server default database not correctly set with Docker Compose #7271

Closed
jdubois opened this issue Mar 11, 2018 · 0 comments
Closed

MS SQL Server default database not correctly set with Docker Compose #7271

jdubois opened this issue Mar 11, 2018 · 0 comments
Milestone

Comments

@jdubois
Copy link
Member

jdubois commented Mar 11, 2018

This was found while working on #7245

The current Docker Compose configuration expects that the MS SQL Server database is called "jhipstertest", which of course doesn't work by default.

Unfortunately, it is not possible to create a MS SQL Server database schema at startup, see microsoft/mssql-docker#2

We could do it by using a complex Docker configuration like we have for MongoDB or Couchbase, but to have a much simpler setup my idea is to use the default "tempdb" that is created by the MS SQL Server Docker image.

  • this will make Docker Compose work
  • if the application is used outside Docker, it will continue to use the "normal" database name, which is the name of the app (as usual with JHipster)
  • the only case that's a bit strange is if you run your app locally, but want to connect to a MS SQL Server instance inside Docker, as in this case you will need to configure the "tempdb" database in the connection String in the application-*.yml configuration file(s)

Of course using "tempdb" isn't good for production use, but I don't think you are allowed to use those images in production (by the Microsoft terms of service), and anyway it's not a recommended use of Docker.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant