Skip to content

Commit

Permalink
Add configuration for wicked_pdf proxy
Browse files Browse the repository at this point in the history
  • Loading branch information
lagoan committed Oct 26, 2020
1 parent d44183d commit 4becdf2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion config/initializers/wicked_pdf.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
module DMPRoadmap
class Application < Rails::Application
WickedPdf.config = {
exe_path: Rails.application.secrets.wicked_pdf_path || '/usr/bin/wkhtmltopdf'
exe_path: Rails.application.secrets.wicked_pdf_path || '/usr/bin/wkhtmltopdf',
proxy: Rails.application.secrets.wicked_pdf_proxy || ''
}
end
end
5 changes: 5 additions & 0 deletions config/secrets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ test:
mailer_default_host: <%= ENV['MAILER_DEFAULT_HOST'] || Socket.gethostname %>
omniauth_full_host: <%= ENV['OMNIAUTH_FULL_HOST'] %>
google_analytics_token: <%= ENV['GOOGLE_ANALYTICS_TOKEN'] %>
wicked_pdf_proxy: <%= ENV['WICKED_PDF_PROXY'] %>

development:
secret_key_base: <%= ENV['SECRET_KEY_BASE'] %>
Expand All @@ -45,6 +46,7 @@ development:
mailer_default_host: <%= ENV['MAILER_DEFAULT_HOST'] || Socket.gethostname %>
omniauth_full_host: <%= ENV['OMNIAUTH_FULL_HOST'] %>
google_analytics_token: <%= ENV['GOOGLE_ANALYTICS_TOKEN'] %>
wicked_pdf_proxy: <%= ENV['WICKED_PDF_PROXY'] %>

staging:
secret_key_base: <%= ENV['SECRET_KEY_BASE'] %>
Expand All @@ -63,6 +65,7 @@ staging:
mailer_default_host: <%= ENV['MAILER_DEFAULT_HOST'] %>
omniauth_full_host: <%= ENV['OMNIAUTH_FULL_HOST'] %>
google_analytics_token: <%= ENV['GOOGLE_ANALYTICS_TOKEN'] %>
wicked_pdf_proxy: <%= ENV['WICKED_PDF_PROXY'] %>

uat:
secret_key_base: <%= ENV['SECRET_KEY_BASE'] %>
Expand All @@ -81,6 +84,7 @@ uat:
mailer_default_host: <%= ENV['MAILER_DEFAULT_HOST'] %>
omniauth_full_host: <%= ENV['OMNIAUTH_FULL_HOST'] %>
google_analytics_token: <%= ENV['GOOGLE_ANALYTICS_TOKEN'] %>
wicked_pdf_proxy: <%= ENV['WICKED_PDF_PROXY'] %>

production:
secret_key_base: <%= ENV['SECRET_KEY_BASE'] %>
Expand All @@ -99,4 +103,5 @@ production:
mailer_default_host: <%= ENV['MAILER_DEFAULT_HOST'] %>
omniauth_full_host: <%= ENV['OMNIAUTH_FULL_HOST'] %>
google_analytics_token: <%= ENV['GOOGLE_ANALYTICS_TOKEN'] %>
wicked_pdf_proxy: <%= ENV['WICKED_PDF_PROXY'] %>

0 comments on commit 4becdf2

Please sign in to comment.