suspenders 1.53.0 → 1.54.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.ruby-version +1 -1
- data/.travis.yml +4 -3
- data/CONTRIBUTING.md +15 -15
- data/GOALS.md +65 -0
- data/NEWS.md +29 -0
- data/README.md +2 -4
- data/docs/heroku_deploy.md +2 -5
- data/lib/suspenders.rb +6 -0
- data/lib/suspenders/actions.rb +2 -2
- data/lib/suspenders/adapters/heroku.rb +14 -1
- data/lib/suspenders/app_builder.rb +3 -71
- data/lib/suspenders/generators/advisories_generator.rb +19 -0
- data/lib/suspenders/generators/app_generator.rb +7 -33
- data/lib/suspenders/generators/base.rb +39 -0
- data/lib/suspenders/generators/ci_generator.rb +19 -9
- data/lib/suspenders/generators/db_optimizations_generator.rb +3 -15
- data/lib/suspenders/generators/js_driver_generator.rb +1 -2
- data/lib/suspenders/generators/preloader_generator.rb +122 -0
- data/lib/suspenders/generators/production/compression_generator.rb +14 -0
- data/lib/suspenders/generators/production/deployment_generator.rb +1 -12
- data/lib/suspenders/generators/production/email_generator.rb +5 -8
- data/lib/suspenders/generators/production/manifest_generator.rb +1 -0
- data/lib/suspenders/generators/production/single_redirect.rb +15 -0
- data/lib/suspenders/generators/production/timeout_generator.rb +1 -0
- data/lib/suspenders/generators/profiler_generator.rb +35 -0
- data/lib/suspenders/generators/runner_generator.rb +48 -0
- data/lib/suspenders/generators/staging/pull_requests_generator.rb +2 -10
- data/lib/suspenders/generators/static_generator.rb +4 -0
- data/lib/suspenders/generators/stylesheet_base_generator.rb +5 -6
- data/lib/suspenders/generators/testing_generator.rb +0 -11
- data/lib/suspenders/version.rb +1 -1
- data/spec/adapters/heroku_spec.rb +28 -2
- data/spec/expand_json_spec.rb +89 -0
- data/spec/features/advisories_spec.rb +24 -0
- data/spec/features/ci_spec.rb +31 -0
- data/spec/features/db_optimizations_spec.rb +19 -0
- data/spec/features/heroku_spec.rb +6 -13
- data/spec/features/new_project_spec.rb +5 -27
- data/spec/features/preloader_spec.rb +25 -0
- data/spec/features/production/compression_spec.rb +23 -0
- data/spec/features/production/manifest_spec.rb +2 -0
- data/spec/features/production/single_redirect_spec.rb +25 -0
- data/spec/features/profiler_spec.rb +20 -0
- data/spec/features/runner_spec.rb +30 -0
- data/spec/features/static_spec.rb +17 -0
- data/spec/support/contain_json_matcher.rb +16 -10
- data/spec/support/project_files.rb +12 -0
- data/spec/support/rails_template.rb +1 -0
- data/spec/support/suspenders.rb +16 -13
- data/suspenders.gemspec +1 -2
- data/templates/Gemfile.erb +1 -6
- data/templates/application.scss +0 -1
- data/templates/bin_auto_migrate +5 -0
- data/templates/bin_deploy +0 -2
- data/templates/bin_setup +2 -2
- data/templates/bin_setup_review_app.erb +0 -1
- data/templates/chromedriver.rb +10 -0
- data/templates/descriptions/advisories.md +5 -0
- data/templates/descriptions/analytics.md +4 -0
- data/templates/descriptions/ci.md +4 -0
- data/templates/descriptions/compression.md +4 -0
- data/templates/descriptions/db_optimizations.md +2 -0
- data/templates/descriptions/deployment.md +5 -0
- data/templates/descriptions/email.md +9 -0
- data/templates/descriptions/factories.md +12 -0
- data/templates/descriptions/force_tls.md +1 -0
- data/templates/descriptions/forms.md +1 -0
- data/templates/descriptions/inline_svg.md +2 -0
- data/templates/descriptions/jobs.md +3 -0
- data/templates/descriptions/js_driver.md +4 -0
- data/templates/descriptions/json.md +1 -0
- data/templates/descriptions/lint.md +3 -0
- data/templates/descriptions/manifest.md +2 -0
- data/templates/descriptions/preloader.md +3 -0
- data/templates/descriptions/profiler.md +7 -0
- data/templates/descriptions/pull_requests.md +4 -0
- data/templates/descriptions/runner.md +10 -0
- data/templates/descriptions/single_redirect.md +1 -0
- data/templates/descriptions/static.md +5 -0
- data/templates/descriptions/stylelint.md +3 -0
- data/templates/descriptions/stylesheet_base.md +4 -0
- data/templates/descriptions/testing.md +9 -0
- data/templates/descriptions/timeout.md +4 -0
- data/templates/descriptions/views.md +8 -0
- data/templates/partials/ci_simplecov.rb +16 -0
- data/templates/partials/db_optimizations_configuration.rb +7 -0
- data/templates/partials/deployment_readme.md +8 -0
- data/templates/partials/email_smtp.rb +3 -0
- data/templates/partials/profiler_readme.md +8 -0
- data/templates/partials/pull_requests_config.rb +5 -0
- data/templates/partials/runner_readme.md +31 -0
- data/templates/partials/runner_setup.rb +3 -0
- data/templates/rack_mini_profiler.rb +2 -0
- data/templates/rails_helper.rb +4 -1
- data/templates/{dotfiles/.env → sample_env} +0 -1
- data/templates/spec_helper.rb +4 -7
- data/templates/spring.rb +6 -0
- data/templates/suspenders_gitignore +1 -1
- metadata +75 -25
- data/templates/dotfiles/.ctags +0 -2
- data/templates/puma.rb +0 -28
data/templates/dotfiles/.ctags
DELETED
data/templates/puma.rb
DELETED
@@ -1,28 +0,0 @@
|
|
1
|
-
# https://devcenter.heroku.com/articles/deploying-rails-applications-with-the-puma-web-server
|
2
|
-
|
3
|
-
# The environment variable WEB_CONCURRENCY may be set to a default value based
|
4
|
-
# on dyno size. To manually configure this value use heroku config:set
|
5
|
-
# WEB_CONCURRENCY.
|
6
|
-
#
|
7
|
-
# Increasing the number of workers will increase the amount of resting memory
|
8
|
-
# your dynos use. Increasing the number of threads will increase the amount of
|
9
|
-
# potential bloat added to your dynos when they are responding to heavy
|
10
|
-
# requests.
|
11
|
-
#
|
12
|
-
# Starting with a low number of workers and threads provides adequate
|
13
|
-
# performance for most applications, even under load, while maintaining a low
|
14
|
-
# risk of overusing memory.
|
15
|
-
workers Integer(ENV.fetch("WEB_CONCURRENCY", 2))
|
16
|
-
threads_count = Integer(ENV.fetch("MAX_THREADS", 2))
|
17
|
-
threads(threads_count, threads_count)
|
18
|
-
|
19
|
-
preload_app!
|
20
|
-
|
21
|
-
rackup DefaultRackup
|
22
|
-
environment ENV.fetch("RACK_ENV", "development")
|
23
|
-
|
24
|
-
on_worker_boot do
|
25
|
-
# Worker specific setup for Rails 4.1+
|
26
|
-
# See: https://devcenter.heroku.com/articles/deploying-rails-applications-with-the-puma-web-server#on-worker-boot
|
27
|
-
ActiveRecord::Base.establish_connection
|
28
|
-
end
|