ruby2-rails5-bootstrap-heroku:一个基于Ruby 2.6,Rails 5.2,Webpack 4,Y

  • b3_152818
  • 243.5KB
  • zip
  • 0
  • VIP专享
  • 0
  • 2022-06-03 14:54
Rails 5 Starter应用程序 这是一个基于以下技术堆栈的实用入门Web应用程序: Starter App可部署在。 演示: : Gemfile还包含一组用于性能,安全性和api构建的有用的gem ... 线程安全 我们假定此应用程序是线程安全的。 如果您的应用程序不是线程安全的或者您不知道,请将puma在Heroku上可用的最小和最大线程数设置为1: $ heroku config:set RAILS_MAX_THREADS=1 主密钥 Rails 5.2引入了。 该存储库使用的主密钥为: b8cc3ac9ab8a3280b03af3d29b2e50ca 不要共享您的
# Rails 5 Starter App [![Build Status](]( [![Code Climate](]( [![Coverage Status](]( [![Deploy](]( This is an opinionated starter web application based on the following technology stack: * [Ruby 2.6.6][1] * [Rails][2] * [Webpack 4][15] * [Yarn][16] * [Puma][3] * [PostgreSQL][4] * [RSpec][5] * [Bootstrap 4.6.0][8] * [Autoprefixer][9] * [Font Awesome 5.15.2 SVG][10] * [Slim][11] * [RuboCop][12] * [RuboCop RSpec][17] * [Slim-Lint][13] * [stylelint][14] [1]: [2]: [3]: [4]: [5]: [8]: [9]: [10]: [11]: [12]: [13]: [14]: [15]: [16]: [17]: Starter App is deployable on [Heroku]( Demo: ```Gemfile``` also contains a set of useful gems for performance, security, api building... ### Thread safety We assume that this application is thread safe. If your application is not thread safe or you don't know, please set the minimum and maximum number of threads usable by puma on Heroku to 1: ```sh $ heroku config:set RAILS_MAX_THREADS=1 ``` ### Master Key Rails 5.2 introduced [encrypted credentials]( The master key used by this repository is: ``` b8cc3ac9ab8a3280b03af3d29b2e50ca ``` **DO NOT SHARE YOUR MASTER KEY. CHANGE THIS MASTER KEY IF YOU ARE GOING TO USE THIS REPO FOR YOUR OWN PROJECT.** ### Heroku Platform API This application supports fast setup and deploy via [app.json]( ```sh $ curl -n -X POST \ -H "Content-Type:application/json" \ -H "Accept:application/vnd.heroku+json; version=3" \ -d '{"source_blob": { "url":""} }' ``` More information: [Setting Up Apps using the Platform API]( ### Recommended add-ons Heroku's [Production Check]( recommends the use of the following add-ons, here in the free version: ```sh $ heroku addons:create newrelic:wayne # App monitoring $ heroku config:set NEW_RELIC_APP_NAME="Rails 5 Starter App" # Set newrelic app name $ heroku addons:create papertrail:choklad # Log monitoring ``` ### Tuning Ruby's RGenGC Generational GC (called RGenGC) was introduced from Ruby 2.1.0. RGenGC reduces marking time dramatically (about x10 faster). However, RGenGC introduce huge memory consumption. This problem has impact especially for small memory machines. Ruby 2.1.1 introduced new environment variable RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR to control full GC timing. By setting this variable to a value lower than the default of 2 (we are using the suggested value of 1.3) you can indirectly force the garbage collector to perform more major GCs, which reduces heap growth. ```sh $ heroku config:set RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR=1.3 ``` More information: [Change the full GC timing](