base: &base
adapter: postgresql
encoding: UTF8
host: localhost
username: xxx
password: xxx
pool: 5
timeout: 5000
development: &development
<<: *base
database: app_development
production: &production
<<: *base
database: app_production
test: &test
<<: *base
database: app_test
如有不同之处,请自行替换。
另外,补充下哈。
如项目打算用到多个数据库,也可在些配置文件中配置。如:
base: &base
...
...
test: &test
<<: *base
database: app_test
anotherdb: &anotherdb
<<: *base
database: anotherdb
在要用到的Model中这样调用:
class Contact < ActiveRecord::Base
establish_connection :anotherdb
...
...
end
分享到:
相关推荐
GraphHopper配置文件,配合web打包jar进行相应GraphHopper服务的配置,配置相关数据策略
天气预报机器人数据集, nlu.yml city.yml response.yml
kubectl apply -f kube-flannel.yml
config.yml
https://github.com/coreos/flannel/blob/master/Documentation/kube-flannel.yml
GitLab Runner 自动部署发布项目的 .gitlab-ci.yml 文件模板
application.yml
elasticsearch.yml 配置文件 ,大自然的搬运工
Spring Boot技术知识点:如何获取application.yml配置文件里的相关属性
server.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.ymlserver.yml
p 127.0.0.1:9200:9200 -p 127.0.0.1:9300:9300 -e "discovery.type=single-node" -v /Users/xingyue/Home/xingyue/学习/工程化/es/elasticsearch.yml:/usr/share/elasticsearch/config/elasticsearch.yml -...
rap2 docker一键安装文件docker-compose.yml ,包括RAP2-DELOS与RAP2-DOLORES. 使用方式参考:https://blog.csdn.net/sondx/article/details/100135558
很好 大家都可以使用 很好的 js资源travis.yml 希望大家使用。