Skip to content

Commit

Permalink
add rack/puma for live review apps
Browse files Browse the repository at this point in the history
  • Loading branch information
indirect committed Apr 29, 2020
1 parent c2c600f commit a4af293
Show file tree
Hide file tree
Showing 7 changed files with 87 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
source 'https://rubygems.org'

gem 'coffee-script'
gem 'github-pages'
gem 'puma', '~> 4.3'
gem 'rack-jekyll', '~> 0.5.0'
gem 'rake'
gem 'sass'
gem 'coffee-script'
10 changes: 10 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ GEM
jekyll-seo-tag (~> 2.1)
minitest (5.14.0)
multipart-post (2.1.1)
nio4r (2.5.2)
nokogiri (1.10.8)
mini_portile2 (~> 2.4.0)
octokit (4.16.0)
Expand All @@ -212,6 +213,13 @@ GEM
pathutil (0.16.2)
forwardable-extended (~> 2.6)
public_suffix (3.1.1)
puma (4.3.3)
nio4r (~> 2.0)
rack (1.6.13)
rack-jekyll (0.5.0)
jekyll (>= 1.3)
listen (>= 1.3)
rack (~> 1.5)
rake (13.0.1)
rb-fsevent (0.10.3)
rb-inotify (0.10.1)
Expand Down Expand Up @@ -245,6 +253,8 @@ PLATFORMS
DEPENDENCIES
coffee-script
github-pages
puma (~> 4.3)
rack-jekyll (~> 0.5.0)
rake
sass

Expand Down
1 change: 1 addition & 0 deletions Procfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
web: bin/puma -p $PORT
12 changes: 12 additions & 0 deletions app.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"name": "rubygems-blog",
"scripts": {
},
"env": {
"LANG": "en_US.UTF-8",
"RACK_ENV": "production"
},
"addons": [

]
}
29 changes: 29 additions & 0 deletions bin/puma
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

#
# This file was generated by Bundler.
#
# The application 'puma' is installed as part of a gem, and
# this file is here to facilitate running it.
#

require "pathname"
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
Pathname.new(__FILE__).realpath)

bundle_binstub = File.expand_path("../bundle", __FILE__)

if File.file?(bundle_binstub)
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
load(bundle_binstub)
else
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
end
end

require "rubygems"
require "bundler/setup"

load Gem.bin_path("puma", "puma")
29 changes: 29 additions & 0 deletions bin/pumactl
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
#!/usr/bin/env ruby
# frozen_string_literal: true

#
# This file was generated by Bundler.
#
# The application 'pumactl' is installed as part of a gem, and
# this file is here to facilitate running it.
#

require "pathname"
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
Pathname.new(__FILE__).realpath)

bundle_binstub = File.expand_path("../bundle", __FILE__)

if File.file?(bundle_binstub)
if File.read(bundle_binstub, 300) =~ /This file was generated by Bundler/
load(bundle_binstub)
else
abort("Your `bin/bundle` was not generated by Bundler, so this binstub cannot run.
Replace `bin/bundle` by running `bundle binstubs bundler --force`, then run this command again.")
end
end

require "rubygems"
require "bundler/setup"

load Gem.bin_path("puma", "pumactl")
3 changes: 3 additions & 0 deletions config.ru
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
require "rack/jekyll"

run Rack::Jekyll.new

0 comments on commit a4af293

Please sign in to comment.