Some comments wrt an install. | GitHub Installation | Forum

Avatar

Please consider registering
Guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —






— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed sp_TopicIcon
Some comments wrt an install.
No permission to create posts
June 3, 2011
8:10 am
Avatar
peterhd
South Africa
New Member
Members
Forum Posts: 2
Member Since:
June 3, 2011
sp_UserOfflineSmall Offline

Hi there

I am a totally newbie to ruby and Thingspeak (but not to linux and hacking (correct sense) around so I thought I might add a few comments with regard to an install.

 

Installing on Slackware 12.1 (oldish).

Ruby version upgraded to: ruby 1.8.7 (2009-06-12 patchlevel 174) [i686-linux]

Rails: Rails 3.0.4

llawlor-thingspeak-5e54790

 

First thing I ran into as a newbie was the idea of production/development/test environments.  By default the install runs in the development environment and does not add the production database to the mysql.  This required switching to the production environment and re-adding the database by setting an environment variable: export RAILS_ENV="production" there are otherways of doing that but that worked for me.  (http://oldwiki.rubyonrails.org/rails/pages/Environments).  This will obviously be required going forward.

 

Once that was set and I was running in the production environment the path for the public folder broke, I have not figured out where to set that correctly yet, I just used:

  # Enable serving of images, stylesheets, and javascripts from an asset server
   config.action_controller.asset_host = "http://mysever/thing/"

By copy the files from public to the a directory in the document root of the local apache  and setting the above it worked fine.

 

I could then create an account but on logging out the login again had a problem.  From the logs the error was:

 

/usr/local/src/llawlor-thingspeak-5e54790/app/views/users/_login.html.erb:1: syntax error, unexpected tASSOC, expecting kEND
…on = UserSession.new), :url => user_session_path, :html => {…

 

Which is this first line:

 

<%= form_for (@user_session = UserSession.new), :url => user_session_path, :html => { :id => 'loginform' } do |f| %>

 

After googling I took a flyer and changed that to this:

 

<%= form_for @user_session, :url => user_session_path, :html => { :id => 'loginform' } do |f| %>

 

And that worked.

 

Next up the link for managing keys does not work.  From the logs:

 

ActionView::Template::Error (compile error
/usr/local/src/llawlor-thingspeak-5e54790/app/views/api_keys/index.html.erb:42: syntax error, unexpected ')'
…path(@channel, :write => 0), );@output_buffer.safe_concat('

 

And still no data being graphed.

 

I will update as I progress.

 

Peter

 

 

June 3, 2011
11:36 am
Avatar
lee

Admin
Forum Posts: 457
Member Since:
March 14, 2011
sp_UserOfflineSmall Offline

We built the application while using Ruby 1.9.2, and have not tested it with older versions of Ruby.  Hopefully if you can upgrade some of the errors will go away.  We also recommend using Phusion Passenger with Nginx as the webserver.  If you have any questions let us know!

 

June 3, 2011
2:44 pm
Avatar
peterhd
South Africa
New Member
Members
Forum Posts: 2
Member Since:
June 3, 2011
sp_UserOfflineSmall Offline

Hi there

Well there you go!  I took your advice and upgraded Ruby etc.  Bingo, all working.

Thank you very much.

 

Now I can play with more interesting things 🙂

 

Peter

Forum Timezone: America/New_York

Most Users Ever Online: 166

Currently Online:
10 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

rw950431: 272

Vinod: 240

piajola: 95

turgo: 70

vespapierre: 63

Adarsh_Murthy: 62

Member Stats:

Guest Posters: 1

Members: 8665

Moderators: 1

Admins: 2

Forum Stats:

Groups: 3

Forums: 14

Topics: 1600

Posts: 5760

Newest Members:

khanhNguyen_CT, susyburr, quijano__, meosuckhoe, briskpanda, Dejw0089

Moderators: cstapels: 460

Administrators: Hans: 405, lee: 457