Skip to content
This repository
Browse code

- removed cucumber_structure.sql from repository and added to gitignore

- updated README
- added aross@opencongress.org email to travis-ci
- removed postgres user references in initial schema
- fixed fixture problems on cucumber tasks
- removed/fixed deprecated rake tasks in plugins (either non-existant or obsolete)
  • Loading branch information...
commit 6dfaa814bfcc763fbbca7f0bfa343174066cd8f2 1 parent 685af63
aross authored February 13, 2012
1  .gitignore
@@ -3,6 +3,7 @@ log/*.log
3 3
 tmp/**/*
4 4
 tmp/*
5 5
 data/*
  6
+db/cucumber_structure.sql
6 7
 db/development_structure.sql
7 8
 db/schema.rb
8 9
 public/assets/*
1  .travis.yml
@@ -8,3 +8,4 @@ script: "bundle exec rake spec"
8 8
 notifications:
9 9
   email:
10 10
     - dougcole@gmail.com
  11
+    - aross@opencongress.org
50  README.md
Source Rendered
@@ -10,7 +10,7 @@
10 10
 
11 11
 ### A. Dependencies
12 12
 
13  
-Start by installing all the packages required by OpenCongress.
  13
+Start by installing all the packages required by OpenCongress.  The main dependencies are postgres and ImageMagick; OpenCongress will not run on mysql or sqlite.  The following commands are suggestions, but ultimately you'll need to get postgres running to be able to run the app.  We are currently running version of postgres 8.4.4 in production.
14 14
 
15 15
 For Ubuntu:
16 16
 
@@ -18,16 +18,21 @@ For Ubuntu:
18 18
 
19 19
 ---
20 20
 
21  
-or Mac OS X, start by installing [MacPorts](http://www.macports.org/), then run:
  21
+For Mac OS X, start by installing [MacPorts](http://www.macports.org/), then run:
22 22
 
23 23
 	sudo port install postgresql84 postgresql84-doc postgresql84-server ImageMagick md5sha1sum wget
24 24
 
25  
-Follow the instructions from the port install for initializing your database
  25
+or, if you want to use [Homebrew](http://mxcl.github.com/homebrew/) (this will install version Postgres 8.4.4):
  26
+	
  27
+	brew install imagemagick
  28
+	brew install https://github.com/adamv/homebrew-alt/raw/master/versions/postgresql8.rb
  29
+ 
  30
+Follow the instructions after the packages install for initializing your database
26 31
 
27 32
 ---
28 33
 
29 34
 
30  
-Then grab the gems you need:
  35
+Install the bundle:
31 36
 
32 37
 <pre>
33 38
 <code>
@@ -36,40 +41,43 @@ bundle install
36 41
 </code>
37 42
 </pre>
38 43
 
39  
-__Note for OS X:__ *You may need to specify additional compile options for the pg gem. Make sure pg_config is in PATH and run* `sudo env ARCHFLAGS="-arch x86_64" gem install pg`
  44
+__Note for OS X:__ *You may need to specify additional compile options for your gems. Try: `ARCHFLAGS="-arch x86_64" bundle install`
40 45
 
41 46
 ### B. Database setup
42 47
 
43  
-Create a postgresql install, based on the database.yml file:
  48
+Running the following commands will create an 'opencongress' user and empty databases for the three environments (test, development, production).  The migration command will populate the development database with an empty schema.
  49
+<pre>
  50
+<code>
44 51
 rake db:init
  52
+rake db:migrate
  53
+</code>
  54
+</pre>
45 55
 
46  
-Import the tsearch2 backwards compatibility lib from wherever your postgres contribs got installed.
  56
+### C. Data (optional)
  57
+
  58
+We are developing a process to quickly import some real legislative data.  Coming soon.
47 59
 	
48  
-	psql opencongress_development < /your/install/share/postgresql/contrib/8.4/tsearch2.sql
  60
+### D. Starting the server
  61
+   
  62
+OpenCongress uses Solr to store some data.  The following command is not required, but some pages will break if Solr is not running:
49 63
 
50  
-`exit` postgres user
  64
+	rake solr:start
51 65
 
52  
-### C. App Setup
  66
+To start the webserver:
53 67
 
54  
-Now you can start the solr server and run the database migrations
  68
+	rails s
55 69
 	
56  
-	cd ..;rake solr:start
57  
-	rake db:structure:load
58  
-	rake db:seed
  70
+---
59 71
 
60  
-### D. Data
61  
-   
62  
-create some dirs for data
  72
+We are actively working to make the install process easier for new volunteers.  Special thanks to Doug Cole for moving us along in this regard.
63 73
 
64  
-Make sure all your data paths are set and exist in your environment file then run `rake update:all` to fetch and parse all available data sources. This process will take a very long time. Take a look at /lib/tasks/daily.rake for all the rake tasks if you want to run them individually.
  74
+---
65 75
 
66  
-Now just a `script/server` and you should be running
67  
- 
68 76
 <div class="hideme"> 
69 77
 
70 78
 <hr />
71 79
 
72  
-<p>Copyright (c) 2005-2010 Participatory Politics Foundation</p>
  80
+<p>Copyright (c) 2005-2012 Participatory Politics Foundation</p>
73 81
 
74 82
 <p>OpenCongress is licensed, as a whole, under AGPLv3. Components added prior to
75 83
 OpenCongress version 3 (July 27, 2011) were and are licensed under GPLv3. All components added for or after
6,702  db/cucumber_structure.sql
0 additions, 6702 deletions not shown
2  db/migrate/initial_schema.sql
@@ -6908,8 +6908,6 @@ CREATE TRIGGER upcoming_bill_tsvectorupdate
6908 6908
 --
6909 6909
 
6910 6910
 REVOKE ALL ON SCHEMA public FROM PUBLIC;
6911  
-REVOKE ALL ON SCHEMA public FROM postgres;
6912  
-GRANT ALL ON SCHEMA public TO postgres;
6913 6911
 GRANT ALL ON SCHEMA public TO PUBLIC;
6914 6912
 
6915 6913
 
4  features/fixtures/users.yml
@@ -10,13 +10,11 @@ users_001:
10 10
   default_filter: "5"
11 11
   mailing: f
12 12
   last_login: 2010-04-02 08:49:05.425035
13  
-  remember_token_expires_at: 
14 13
   crypted_password: e9df7394fdecfe1d3c354ef7818ba93ba9c67578
15 14
   chat_msn: ""
16 15
   zipcode: 01084
17 16
   password_reset_code: 
18 17
   updated_at: 2010-04-02 08:49:05.426847
19  
-  sso_key: 
20 18
   zip_four: "9605"
21 19
   activation_code: 
22 20
   admin: f
@@ -68,13 +66,11 @@ users_002:
68 66
   default_filter: "5"
69 67
   mailing: t
70 68
   last_login: 2010-04-06 14:26:56.149317
71  
-  remember_token_expires_at: 
72 69
   crypted_password: 0789967153cdd211bc1d07852a4eb26c0530c0d4
73 70
   chat_msn: 
74 71
   zipcode: "20002"
75 72
   password_reset_code: 
76 73
   updated_at: 2010-04-06 14:26:56.151032
77  
-  sso_key: 
78 74
   zip_four: 
79 75
   activation_code: 
80 76
   admin: f
2  lib/tasks/hoptoad_notifier_tasks.rake
@@ -3,7 +3,7 @@
3 3
 # https://thoughtbot.lighthouseapp.com/projects/14221/tickets/629
4 4
 unless ARGV.any? {|a| a =~ /^gems/} 
5 5
 
6  
-  Dir[File.join(RAILS_ROOT, 'vendor', 'gems', 'hoptoad_notifier-*')].each do |vendored_notifier|
  6
+  Dir[File.join(Rails.root.to_s, 'vendor', 'gems', 'hoptoad_notifier-*')].each do |vendored_notifier|
7 7
     $: << File.join(vendored_notifier, 'lib')
8 8
   end
9 9
 
4  vendor/plugins/acts_as_bookmarkable/tasks/acts_as_bookmarkable_tasks.rake
... ...
@@ -1,4 +0,0 @@
1  
-# desc "Explaining what the task does"
2  
-# task :acts_as_bookmarkable do
3  
-#   # Task goes here
4  
-# end
24  vendor/plugins/open_flash_chart_2/tasks/open_flash_chart_tasks.rake
... ...
@@ -1,24 +0,0 @@
1  
-namespace :open_flash_chart_2 do
2  
-  PLUGIN_ROOT = File.dirname(__FILE__) + '/../'
3  
-
4  
-  desc 'Installs required swf in public/ and javascript files to the public/javascripts directory.'
5  
-  task :install do
6  
-    FileUtils.cp "#{PLUGIN_ROOT}requirements/open-flash-chart.swf", "#{RAILS_ROOT}/public/", :verbose => true
7  
-    FileUtils.cp "#{PLUGIN_ROOT}requirements/swfobject.js", "#{RAILS_ROOT}/public/javascripts/", :verbose => true
8  
-  end
9  
-
10  
-  desc 'Removes the swf and javascripts for the plugin.'
11  
-  task :uninstall do
12  
-    FileUtils.rm "#{RAILS_ROOT}/public/javascripts/swfobject.js", :force => true, :verbose => true
13  
-    FileUtils.rm "#{RAILS_ROOT}/public/open-flash-chart.swf", :force => true, :verbose => true
14  
-  end
15  
-
16  
-  desc 'Removes the old swf and javascripts for the plugin and copy new one to public direcory.'
17  
-  task :reinstall do
18  
-    FileUtils.rm "#{RAILS_ROOT}/public/javascripts/swfobject.js", :force => true, :verbose => true
19  
-    FileUtils.rm "#{RAILS_ROOT}/public/open-flash-chart.swf", :force => true, :verbose => true
20  
-
21  
-    FileUtils.cp "#{PLUGIN_ROOT}requirements/open-flash-chart.swf", "#{RAILS_ROOT}/public/", :verbose => true
22  
-    FileUtils.cp "#{PLUGIN_ROOT}requirements/swfobject.js", "#{RAILS_ROOT}/public/javascripts/", :verbose => true
23  
-  end
24  
-end
4  vendor/plugins/remote_forgery_protection/tasks/remote_forgery_protection_tasks.rake
... ...
@@ -1,4 +0,0 @@
1  
-# desc "Explaining what the task does"
2  
-# task :remote_forgery_protection do
3  
-#   # Task goes here
4  
-# end

0 notes on commit 6dfaa81

Please sign in to comment.
Something went wrong with that request. Please try again.