Ruby 2.5 preparation


#1

https://github.com/zammad/zammad/issues/2313 was closed, and suggested I bring it up here. This is what I figured out, in getting the app to compile under Ruby 2.5 / Ubuntu 18.04.

  • Gemfile changes: ruby ‘2.4.4’ -> ruby ‘2.5.0’ ; gem ‘rails’, ‘5.1.5’ -> gem ‘rails’, '5.2.1’
  • Gemfile addition: gem ‘activerecord’, '5.2.1’
  • Gemfile addition: gem ‘sassc-rails’ ; Reference & Deprecation of Sass
  • Gemfile deletions: gem ‘libv8’ and gem 'therubyracer’
  • Need to install NodeJS + add ENV[‘EXECJS_RUNTIME’] = ‘Node’ to config/boot.rb ; Reference

#2
  • I used rubocop & SemiStandardJS to lint the content of the project.
  • I made updated adjustments to what I originally suggested above. The Gemfile in the fork has said adjustments.
  • There’s now an install.sh script, that can be used for the steps after the zammad user is created, and /opt/zammad is ready for use.

Still getting the following error though on viewing tickets…

Status Code: 422. {“error”:“PG::UndefinedTable: ERROR: missing FROM-clause entry for table “groups”\nLINE 1: … $2 AND (“groupsusers”.“access”) IN ($3, $4) AND “groups”.”…\n ^\n: SELECT 1 AS one FROM “groupsusers” WHERE “groupsusers”.“userid” = $1 AND “groupsusers”.“groupid” = $2 AND (“groups_users”.“access”) IN ($3, $4) AND “groups”.“active” = $5 LIMIT $6"}


#3

https://www.engineyard.com/blog/rails-encrypted-credentials-on-rails-5.2 Another thing I found, regarding Rails 5.2 changes. Credentials use has to be encrypted.


#4

Install tips as of November 2018 Updated install instructions for Ruby 2.4 on Ubuntu 16.04.5