Permalink
Browse files

Heroku support

  • Loading branch information...
1 parent c87fea1 commit 8165276aae9fe3e8a7577ded852c8a48c31c02bf @distler distler committed May 27, 2016
Showing with 132 additions and 32 deletions.
  1. +27 −0 Gemfile.heroku
  2. +65 −0 Gemfile.lock.heroku
  3. +37 −30 README → README.md
  4. +3 −2 config/environments/production.rb
View
@@ -0,0 +1,27 @@
+source "http://rubygems.org"
+gem "itextomml", ">=1.5.1"
+gem "rack", ">=1.1.3"
+gem "thin"
+gem "rubyzip", '~> 0.9.9'
+gem "RedCloth", ">=4.0.0"
+gem "erubis"
+gem "nokogiri", '~>1.5.6'
+gem "rake", '~>10.4.0'
+gem "rdoc"
+gem "json"
+gem "abstract", "~> 1.0.0"
+gem "rails_xss", "~> 0.4.0"
+gem "file_signature", "~> 1.2.0"
+gem "syntax", "~> 1.1.0"
+gem "maruku", :git => 'git://github.com/distler/maruku.git', :branch => 'nokogiri'
+gem 'iconv', :platforms => [:ruby_20, :ruby_21, :ruby_22, :ruby_23]
+gem 'rdoc-data', :platforms => :ruby_18
+gem 'test-unit', '~> 2.5.5'
+
+group :development, :test do
+ gem "sqlite3", :require => "sqlite3"
+end
+
+group :production do
+ gem "pg"
+end
View
@@ -0,0 +1,65 @@
+GIT
+ remote: git://github.com/distler/maruku.git
+ revision: c67cc8375dd70bae30d7277dc54ccba04802b316
+ branch: nokogiri
+ specs:
+ maruku (0.7.3.beta1)
+ itextomml (>= 1.5.0)
+ nokogiri (~> 1.5, >= 1.5.6)
+ syntax (~> 1.1.0)
+
+GEM
+ remote: http://rubygems.org/
+ specs:
+ RedCloth (4.3.0)
+ abstract (1.0.0)
+ daemons (1.2.3)
+ erubis (2.7.0)
+ eventmachine (1.2.0.1)
+ file_signature (1.2.0)
+ iconv (1.0.4)
+ itextomml (1.5.2)
+ json (1.8.3)
+ nokogiri (1.5.11)
+ rack (1.6.4)
+ rails_xss (0.4.0)
+ rake (10.4.2)
+ rdoc (4.2.2)
+ json (~> 1.4)
+ rdoc-data (4.1.0)
+ rdoc (~> 4.0)
+ gem_plugin (0.2.3)
+ pg (0.14.1)
+ rubyzip (0.9.9)
+ sqlite3 (1.3.11)
+ syntax (1.1.0)
+ test-unit (2.5.5)
+ thin (1.6.4)
+ daemons (~> 1.0, >= 1.0.9)
+ eventmachine (~> 1.0, >= 1.0.4)
+ rack (~> 1.0)
+
+PLATFORMS
+ ruby
+
+DEPENDENCIES
+ RedCloth (>= 4.0.0)
+ abstract (~> 1.0.0)
+ erubis
+ file_signature (~> 1.2.0)
+ iconv
+ itextomml (>= 1.5.1)
+ json
+ maruku!
+ nokogiri (~> 1.5.6)
+ rack (>= 1.1.3)
+ rails_xss (~> 0.4.0)
+ rake (~> 10.4.0)
+ pg
+ rdoc
+ rdoc-data
+ rubyzip (~> 0.9.9)
+ sqlite3
+ syntax (~> 1.1.0)
+ test-unit (~> 2.5.5)
+ thin
View
@@ -1,51 +1,55 @@
-
-= Instiki
+# Instiki
Instiki is a wiki clone so pretty and easy to set up, you'll wonder if it’s really a wiki. Runs on Rails and focuses on portability and stability. Supports file uploads, PDF export, RSS, multiple users and password protection. Some use Instiki as a CMS (Content Management System) because of its ability to export static pages.
Instiki lowers the barriers of interest for when you might consider using a wiki. It's so simple to get running that you'll find yourself using it for anything -- taking notes, brainstorming, organizing a gathering.
+## Supported Platforms
-== Supported Platforms
-
-Instiki only relies on Ruby - the sole external dependency (it includes all other dependencies). Any OS that can run Ruby can run Instiki - that includes Windows, Linux, Mac OS X and most known Unix flavors.
-
-Instiki on BeOS, Amiga OS, OS2, Zeta OS and support for various exotic Platforms is planned. Mostly it already works, if Ruby runs there (download the linux version in this case). Please contact parasew if you want to help out for your OS that is not listed. Please also get in touch if you are able to create an instiki package for your favorite unix or linux distribution.
+Instiki only requires a working Ruby installation (it includes all other dependencies). Any OS that can run Ruby can run Instiki - that includes Windows, Linux, Mac OS X and most known Unix flavors.
-
-== 3 easy Steps to get the Instiki experience
+### 3 easy Steps to get the Instiki experience
Step 1. Get Instiki and run "ruby bundle install --path vendor/bundle"
Step 2. Run "instiki"
Step 3. Chuckle... "There's no step three!" (TM)
-== Details
+## Details
You need at least Ruby Version 1.8.6, and Rubygems 1.3.6, installed on your System. The second dependency is a Database System, but don't worry, the default sqlite3 will be installed for you, if it's not already installed. You can also use any other database system (MySQL, PostgreSQL, ...) supported by Rails.
+### Deploy to Heroku
+
+- git clone https://github.com/parasew/instiki.git
+- cd instiki
+- heroku create [APPNAME]
+- mv Gemfile Gemfile.orig
+- git mv Gemfile.heroku Gemfile
+- git mv Gemfile.lock.heroku Gemfile.lock
+- git commit -m "Setup for heroku"
+- git push heroku master
+- heroku run rake db:migrate
-=== If you are on Windows
+### If you are on Windows
- Get the *Ruby One-Click Installer - Windows* http://rubyforge.org/projects/rubyinstaller
- Get Development Kit http://github.com/oneclick/rubyinstaller/wiki/development-kit
- In the Instiki directory, execute "ruby bundle"
- double-click instiki.bat or instiki.cmd and there you go!
-=== If you are on Mac OSX
+### If you are on Mac OSX
-On Leopard and Snow Leopard, you are all set.
+On Snow Leopard (10.6) or later, you are all set.
- run "sudo gem update --system" via the command-line.
- run "ruby bundle install --path vendor/bundle" in the instiki directory.
- run "ruby instiki" and there you go!
-Tiger ships with a really old Ruby Version (1.8.2) and a broken Readline Library you have to
-- use the Ruby One-Click-Installer for OSX ( http://rubyosx.com ) if you don't already have macports' Ruby
-=== If you are on Linux
+### If you are on Linux
-=== Any other System
+### Any other System
- get Ruby for your System, compile if nessesary: http://ruby-lang.org
- Depending on the version of Rubygems that came with your Ruby, you may need to
@@ -59,7 +63,7 @@ Tiger ships with a really old Ruby Version (1.8.2) and a broken Readline Library
You're now running a perfectly suitable wiki on port 2500 that'll present you with one-step setup, followed by a textarea for the home page on http://localhost:2500
-== Features
+## Features
* Regular expression search: Find deep stuff really fast
* Revisions: Follow the changes on every page from birth. Rollback to an earlier rev
@@ -76,39 +80,42 @@ You're now running a perfectly suitable wiki on port 2500 that'll present you wi
Markdown
Textile [http://www.textism.com/tools/textile]
RDoc [http://rdoc.sourceforge.net/doc]
-* Support for Math (using itex syntax [http://golem.ph.utexas.edu/~distler/blog/itex2MMLcommands.html])
+* Support for Math (using [itex syntax](https://golem.ph.utexas.edu/~distler/blog/itex2MMLcommands.html))
* Support for WYSIWYG SVG editing -- embed SVG graphics right in your wiki page.
* Embedded webserver: uses Mongrel (if installed), or the bundled WEBrick webserver (if not).
* Internationalization: Wiki words in any latin, greek, cyrillian, or armenian characters
* Color diffs: Track changes through revisions
* Runs on SQLite3 per default, can be configured to run on PostgreSQL, MySQL, DB2, Firebird, Openbase, Oracle, SQL Server or Sybase
-== Command-line options:
+## Command-line options:
* Run "ruby instiki --help"
-== History:
+## History:
* See CHANGELOG
-== Migrating from Instiki 0.11-0.18 to 0.19
+## Migrating from Instiki 0.11-0.18 to 0.19
ruby bundle install --path vendor/bundle
ruby bundle exec rake upgrade_instiki
-== Download the latest release from:
+## Download the latest release from:
+
+* https://github.com/parasew/instiki/releases
-* http://rubyforge.org/project/showfiles.php?group_id=186
+## Visit the Instiki wiki:
-== Visit the Instiki wiki:
+* https://golem.ph.utexas.edu/wiki/instiki/
-* http://golem.ph.utexas.edu/wiki/instiki/
+## Visit the Instiki users forum
+* https://golem.ph.utexas.edu/forum/forums/instiki
-== License:
+## License:
* same as Ruby's
@@ -119,16 +126,16 @@ Authors::
Versions 0.0 to 0.9.1:: David Heinemeier Hansson
Email:: david[AT]loudthinking.com
-Weblog:: http://www.loudthinking.com[http://www.loudthinking.com]
+Weblog:: (http://www.loudthinking.com)[http://www.loudthinking.com]
From 0.9.2 onwards:: Alexey Verkhovsky
Email:: alex[AT]verk.info
From 0.11 onwards:: Matthias Tarasiewicz and 5uper.net
Email:: parasew[AT]gmail.com
-Website:: http://5uper.net[http://5uper.net]
+Website:: (http://5uper.net)[http://5uper.net]
From 0.13 onwards:: Matthias Tarasiewicz and Jacques Distler
-Email:: instiki-devel[AT]rubyforge.org
+Email:: jdistler-instiki[AT]golem.ph.utexas.edu
Weblog Jacques: http://golem.ph.utexas.edu/~distler/blog/
Weblog Parasew: http://parasew.com
@@ -7,8 +7,9 @@
####
# This rotates the log file, keeping 25 files, of 1MB each.
-
-config.action_controller.logger = Logger.new(Rails.root.join('log', "#{RAILS_ENV}.log"), 25, 1024000)
+# If we are running on heroku, log to STDOUT instead.
+config.action_controller.logger = ENV["HEROKU_POSTGRESQL_NAVY_URL"] ? Logger.new(STDOUT) :
+ Logger.new(Rails.root.join('log', "#{RAILS_ENV}.log"), 25, 1024000)
# Unfortunately, the above does not work well under Mongrel, as the default Ruby logger class
# does no locking and you will have several processes running, each wanting to write to (and

0 comments on commit 8165276

Please sign in to comment.