Meego Wiki
Views

Quality/QA-tools/QAReports/Setting up the development environment

From MeeGo wiki
(Difference between revisions)
Jump to: navigation, search
m (Set up QA Reports: More dependencies are needed to get gems installed)
m (Set up QA Reports: Rack installation manually first makes qa-reports bundling work, it seems)
Line 22: Line 22:
# Install preqrequisites: <tt>$ sudo apt-get install libmysqlclient-dev libxml2-dev libxslt1-dev</tt>
# Install preqrequisites: <tt>$ sudo apt-get install libmysqlclient-dev libxml2-dev libxslt1-dev</tt>
# Create database config to <tt>qa-reports/config/database.yml</tt> (example exists by name <tt>database.example.yml</tt>)
# Create database config to <tt>qa-reports/config/database.yml</tt> (example exists by name <tt>database.example.yml</tt>)
-
# Check <tt>qa-reports/Gemfile</tt>
+
# Install gem <tt>rack</tt> to get what's needed to be able to use the git version: <tt>$ gem install rack</tt>
-
## If there's a line <tt>gem 'rack', :git => "git://github.com/rack/rack.git"</tt>, change it to <tt>gem 'rack', '1.2.1'</tt>
+
-
## Apparently the dependencies are not installed with the git approach which will lead into server starting failure
+
Follow the instructions then from <tt>qa-reports/README.creole</tt>:
Follow the instructions then from <tt>qa-reports/README.creole</tt>:
Line 31: Line 29:
# <tt>$ gem install bundler --no-ri --no-rdoc</tt>
# <tt>$ gem install bundler --no-ri --no-rdoc</tt>
# <tt>$ bundle install --without staging production</tt>
# <tt>$ bundle install --without staging production</tt>
-
## If you had to edit the Gemfile, you can now change it back the way it was and run the <tt>bundle</tt> command again to make it use the version in git (if that's needed)
 
# <tt>$ rake db:create</tt>
# <tt>$ rake db:create</tt>
# <tt>$ rake db:migrate</tt>
# <tt>$ rake db:migrate</tt>
## Failed, but after rerun worked
## Failed, but after rerun worked
# Start the server: <tt>$ rails server</tt>
# Start the server: <tt>$ rails server</tt>

Revision as of 06:02, 19 January 2011

Introduction

QA Reports is a Ruby on Rails application so you need to install a bunch of stuff to get it up and running. This draft documentation is based on experiences in installation on Ubuntu 10.10

Installing Ruby

Most likely you won't succeed with the packaged version of Ruby. Thus this guide uses Ruby Version Manager (rvm).

  1. Install dependencies: $ sudo apt-get install git-core curl
  2. Install rvm: $ bash < <( curl http://rvm.beginrescueend.com/releases/rvm-install-head )
  3. Follow the instructions printed once installation is ready
    1. Install needed packages - check section "For Ruby (MRI & ree) you should install the following OS dependencies"
    2. Enable loading of rvm - check section "You must now complete the install by loading RVM in new shells"
      1. Edit .bashrc as described
      2. Restart your shell to have rvm enabled
  4. Install Ruby: $ rvm install 1.8.7
  5. Set into use: $ rvm use 1.8.7

Set up QA Reports

  1. Clone qa-reports from git: $ git clone git://gitorious.org/meego-quality-assurance/qa-reports.git
  2. Install preqrequisites: $ sudo apt-get install libmysqlclient-dev libxml2-dev libxslt1-dev
  3. Create database config to qa-reports/config/database.yml (example exists by name database.example.yml)
  4. Install gem rack to get what's needed to be able to use the git version: $ gem install rack

Follow the instructions then from qa-reports/README.creole:

  1. $ gem update --system
    1. Note: if you get an error about zlib, follow these instructions
  2. $ gem install bundler --no-ri --no-rdoc
  3. $ bundle install --without staging production
  4. $ rake db:create
  5. $ rake db:migrate
    1. Failed, but after rerun worked
  6. Start the server: $ rails server
Personal tools