Skip to content

Commit

Permalink
Changes requested by @yivo
Browse files Browse the repository at this point in the history
  • Loading branch information
Yaroslav Savchuk committed Jan 9, 2018
1 parent 60944b5 commit a3c9951
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 31 deletions.
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@ RUN su app -s /bin/bash -c "bundle install --path /opt/vendor/bundle"
# Copy the main application.
COPY . $APP_HOME

RUN chown -R app:app /home/app
RUN chown -R app:app /home/app && \
mv config/database.yml.example config/database.yml
USER app

RUN bundle exec rake tmp:create assets:precompile
Expand Down
4 changes: 2 additions & 2 deletions config/charts/barong/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ It is pre-install hook, so we don't have secrets created yet and we need to use
- name: COOKIES_SECRET_KEY
value: ""
{{- if .Values.db.password }}
- name: DATABASE_PASS
- name: DATABASE_PASSWORD
value: {{ .Values.db.password }}
{{- end }}
{{- end -}}
Expand Down Expand Up @@ -66,7 +66,7 @@ Environment for barong container
name: {{ template "fullname" . }}
key: cookiesSecretKey
{{- if .Values.db.password }}
- name: DATABASE_PASS
- name: DATABASE_PASSWORD
valueFrom:
secretKeyRef:
name: {{ template "fullname" . }}
Expand Down
21 changes: 0 additions & 21 deletions config/database.yml

This file was deleted.

14 changes: 7 additions & 7 deletions config/database.yml.example
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
default: &default
adapter: mysql2
adapter: mysql2
encoding: utf8
pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
username: root
password: root
host: localhost
password:
host: localhost

development:
<<: *default
Expand All @@ -16,6 +16,6 @@ test:

production:
<<: *default
database: barong_production
username: barong
password: <%= ENV['BARONG_DATABASE_PASSWORD'] %>
database: <%= ENV.fetch('DATABASE_NAME') %>
username: <%= ENV.fetch('DATABASE_USER') %>
password: <%= ENV.fetch('DATABASE_PASSWORD') %>

0 comments on commit a3c9951

Please sign in to comment.