Use database YAML file instead of env variable

pull/4273/head
Cyril Rohr 9 years ago
parent c048c7b58d
commit 413de3080a
  1. 42
      config/database.docker.yml
  2. 3
      doc/QUICK_START.md
  3. 1
      docker-compose.yml

@ -0,0 +1,42 @@
#-- copyright
# OpenProject is a project management system.
# Copyright (C) 2012-2015 the OpenProject Foundation (OPF)
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License version 3.
#
# OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:
# Copyright (C) 2006-2013 Jean-Philippe Lang
# Copyright (C) 2010-2013 the ChiliProject Team
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# See doc/COPYRIGHT.rdoc for more details.
#++
development: &mysql
adapter: mysql2
database: openproject_development
host: db
username: root
password:
encoding: utf8
# Warning: The database defined as "test" will be erased and
# re-generated from your development database when you run "rake".
# Do not set this db to the same as development or production.
test:
<<: *mysql
database: openproject_test

@ -51,7 +51,8 @@ You can find information on configuring OpenProject in [`config/CONFIGURATION.md
2. Start and setup the database
docker-compose up -d db
docker-compose run db rake db:create db:migrate db:seed
cp config/database.docker.yml config/database.yml
docker-compose run web rake db:create db:migrate db:seed
3. Start the other processes

@ -14,7 +14,6 @@ worker: &ruby
links:
- db
environment:
- "DATABASE_URL=mysql2://root@db/openproject_development?encoding=utf8"
- "RAILS_CACHE_STORE=file_store"
command: "./docker/worker"

Loading…
Cancel
Save