Ruby is a dynamic, reflective, general-purpose object-oriented programming language that combines syntax inspired by Perl with Smalltalk-like features.

learn more… | top users | synonyms

3
votes
0answers
37 views

Can using chcon to essentially bypass selinux be less secure than setting selinux to permissive?

I was wondering if it is possible to make a CentOS 7 server less secure by using chcon than it would be if SELinux were in Permissive mode. I am essentially trying to set up Phusion Passenger with ...
0
votes
0answers
10 views

Ruby with Tk in Gentoo

How to emerge Ruby with tk/tcl support in Gentoo Linux. I've tried USE="tk" emerge ruby, but it didn't work. Furthermore there is no tk use flag according ...
1
vote
2answers
47 views

Ruby gems not recognized in bash script

I have built a node.js app that listens for webhooks. Currently it is used to build a jekyll website. I have configured it on my server and jekyll build works perfectly when I run it in the root of ...
2
votes
1answer
299 views

`ERROR: Failed to build gem native extension` while trying to install compass

I am using Ubuntu 14.04 I tried this command sudo gem install compass and it gave me this error: Fetching: multi_json-1.11.2.gem (100%) Fetching: compass-core-1.0.3.gem (100%) Fetching: ...
0
votes
1answer
82 views

“ruby: Command not found” on FreeBSD, despite having installed it

I just tried to run a ruby script on a FreeBSD box I hadn't used in a while, and got "ruby: Command not found." So I figured I just hadn't previously installed it. Went to /usr/ports/lang/ruby22 and ...
0
votes
1answer
104 views

Puppet Master: TCPServer Error: Address already in use - bind(2) - WEBrick 1.3.1

I rebooted Puppet Master several times but always this error [root@puppet-master04 ~]# service httpd restart Stopping httpd: [ OK ] Starting httpd: ...
1
vote
0answers
111 views

Issues Installing Ruby without sudo

I am migrating a website to a server that is running Ubuntu 14.04.2 LTS, the website is managed through git and built using Jekyll. Jekyll is installed as ruby gem and unfortunately the server does ...
1
vote
0answers
32 views

installed font not working in ec2 in rails app

I have downloaded font by running wget http://www.fontsquirrel.com/fonts/download/amatic inside my ec2 instance. Then I created a .fonts director and unzipped those files inside it. Then I ls ...
2
votes
4answers
74 views

Copy files to new directory only if name of file is in an array

I'm not much of a zsh buff but I imagine this should be an easy layup for someone: I can bulk copy files from sourcedir to targetdir with the following: $ find sourcedir -type f -exec cp {} ...
0
votes
0answers
38 views

Resizing image with ImageMagick and Ruby on Rails

I have been trying to use Imagemagick to resize images uploaded by a user as a square. Currently, I am using the ! like so - 640x640! This works fine if the image I feed it is a resolution of ...
0
votes
1answer
39 views

SSH run command in users rbenv enviroment

Anyone know how to make ssh source the users enviroment? ssh -Y -t old-dash '"bundle exec rails server" bash: bundle exec rails server: command not found Connection to old-dash closed. ...
2
votes
1answer
74 views

EACCESS err while installing thin

I am trying to install thin in linux mint 17. I have installed ruby via rvm . I have already install the thin gem. When I ran thin install I got this error Installing thin service at ...
0
votes
1answer
23 views

How can I check the ruby format for a bunch of files and/or 1 single file?

Most of them have a common pattern that is a filename of ..._rspec.rb One of them is a filename without that ending (but does end in .rb) How can I run ruby -wc (or in fact any operations such as ...
0
votes
0answers
50 views

umask issue with apache phusion passenger

We have a rails application where a unix account will write to directory belonging to another unix account. I have added both the accounts to a common group. The new file which is getting created does ...
0
votes
0answers
94 views

yum update conflict rubygem-passenger-native-libs from passenger repository vs centOS updates

yum update on a puppet dashboard throws up following error. How do we resolve it safely? Error: Package: 1:rubygem-passenger-native-libs-3.0.19- 1.el6_1.8.7.352.x86_64 (passenger-centos6-x86_64) ...
0
votes
0answers
68 views

Openssl support for ruby not found in passenger installation on redhat 6

I have openssl 1.0.1e-42.el6 already installed. Also tried to compile openssl from ext/openssl directory which failed with below error ossl_pkey_ec.c:815: error: ‘EC_GROUP_new_curve_GF2m’ undeclared ...
0
votes
2answers
81 views

Linux 'make' command fails after installing ruby and gems for biopieces

We wanted to try the biopieces tools, which require certain dependencies, such as ruby and perl, a.o. After running the installers, and consequently installing some ruby gems, we were not able to run ...
1
vote
2answers
223 views

Remove lines from CSV file if the second column is in a word list

I have found a long list of free email providers that I want to remove from my email lists - https://gist.github.com/tbrianjones/5992856 Below are two commands I currently use that do the same job ...
0
votes
0answers
98 views

How to check if Nginx + Ruby on Rails web application is down?

I am very new to *nix system. I have below setup: OS - Ubuntu 14.14 Web Server - Nginx with Passenger Web Application Ruby on Rails web application Please tell me what tools to use to achieve: ...
-1
votes
1answer
3k views

How to install Ruby 2.0.0 in kali linux?

Currently i have version 1.9 of Ruby installed. I need to install arachni we scanner which requires version 2.0.0. or later. How can i upgrade it to v 2.0.0?
0
votes
0answers
16 views

Trouble with postfix configuration to communicate with ruby application

This could be such a wide range of things but i hope posting here would narrow it down, i have this application installed and running in a web browser https://bitbucket.org/naushniki/qamail/src and ...
0
votes
0answers
17 views

Tab separated output for multipath -ll, uname -a , ifconfig -a , hostname using Ruby

I'll like to use Ruby to produce a tab separated output file of mutipath -ll, ifconfig -a , uname , cat /etc/sysconfig/network-scripts/route-eth0 comands
0
votes
1answer
192 views

Subdomain Creation in Amazon EC2 using Nginx Server [closed]

I am using amazon ec2.... My app is written in Ruby on Rails. I am using Nginx Server. How can I create sub-domain and automate it when a user registers like http://user.mywebsite.com?
0
votes
0answers
28 views

Im using Whonix, How to set Directory where I upload my website to on local machine

Im using whonix Gateway and Workstation. I have them installed correctly and I can access the tor through them. Im trying to publish an .onion website. I have a website written in Ruby Rails. How ...
1
vote
0answers
631 views

How can I run script without root to sniff network (libpcap)?

I have a script (in ruby): require 'ffi/pcap' pcap = FFI::PCap::Live.new(:dev => "wlan0", :timeout => 1) pcap.loop() do |this,pkt| puts pkt.body end When I try to run the script , I get ...
1
vote
1answer
828 views

Installing ruby 2.1 on Ubuntu 12.04 using ruby-install application

I've been through a couple of tutorials on how to install ruby 2.1.* My system currently has ruby 1.9.3 and I want the latest one. I'm following the following tutorial on how to install it from here: ...
2
votes
0answers
25 views

problems running brew

I have a macbook pro running OS X 10.10.1 with home-brew installed, but it is giving me some problems. When I tried to run brew doctor after having installed it I got the message. ...
-2
votes
1answer
274 views

bash for loop to run ruby scripts

I'm trying to run several ruby scripts from the command line. Here is my code so far: for i in {1..59}; do $("ruby sample$i.rb"); sleep 10; done The purpose is to test all these scripts quickly, ...
0
votes
1answer
460 views

`rvm list remote` not showing binaries for Ubuntu 14.04 box

I'm trying to provision a dev box with rvm on Ubuntu 14.04 (via Vagrant and Ansible). I've installed rvm: gpg --keyserver hkp://keys.gnupg.net --recv-keys D39DC0E3 \curl -sSL https://get.rvm.io | ...
2
votes
2answers
124 views

How can I test for a file having a value?

I am using source ~/.rvm/scripts/rvm repos="repo_1_ruby_193 repo_2_ruby_211 repo_3_ruby_191" > rvm_check.txt for repo in $repos do cd ~/zipcar/$repo 2>rvm_check.txt cd .. echo $repo if ...
0
votes
2answers
159 views

How to change installed ruby version

I am trying to run ruby on my RPi (Raspbian/Debian distro). I have installed ruby with apt-get command, but it has installed 1.9. 3 version. I wanted newer one, so I removed that one and next, ...
2
votes
2answers
319 views

How to select unique array values?

I have an array and I want to get the unique 2nd members bash doesn't really have 2-dimensional array so I've defined it this way, using :: as the separator of the two elements: ruby_versions=( ...
1
vote
1answer
119 views

How to wrap iptables commands around Ruby webrick server going up and down in a single command/script?

I would like to use this Ruby WEBrick server solution for on-demand showcasing of some random web pages. So I set up some forwarding exception on my adsl modem local web interface(192.168.2.1). Then ...
0
votes
1answer
96 views

Can we input or send any text to the daemon?

I have some ‍upload/download ruby scripts; I want to run those scripts in daemon process. When I run ruby script on terminal, it ask for some input after that script start to execute. So now I want to ...
-1
votes
1answer
425 views

Ruby alternative to fabric [closed]

Is there a Ruby alternative to Python based Fabric?
0
votes
2answers
297 views

Installing Jekyll on Elementary OS using gem

When I try to install Jekyll on Elementary OS Luna with the command sudo gem install jekyll --no-rdoc --no-ri I get the following error. -- rbconfig (LoadError) from ...
2
votes
1answer
50 views

How can I syntax highlight Ruby range bounds in gtksourceview3.0?

I do most of my coding in gedit, which highlights integers and other syntax. When I use an integer range in Ruby, represented as 0..3 for example, the integers are not properly highlighted and are ...
1
vote
1answer
235 views

calling script from perl/python/ruby and retrieving output [closed]

I inherited a tcsh "master" script that works and extracts lines from files with data with using 'zcat' piped to 'grep' and some other commands/scripts. The extracted lines contain numbers . It is ...
0
votes
1answer
99 views

How to create CronJob for running commands on reboot?

Via my host I have SSH access and a control panel. I installed Rails via SSH on a light weight server. I want to reboot the server when it goes down. I think I need to start it manually since I want ...
7
votes
3answers
721 views

How to configure Ruby to use the correct gemset or Ruby version on a per-project basis?

I open a terminal and navigate to my project folder (ex: cd /proj/tickecting_app). After this I execute this command: rvm use ruby 1.9.x@gemset . I want this command to run this every time I open the ...
1
vote
1answer
343 views

Installing rvm and a specific version of ruby using rvm on linux based systems

UI testing is done using ruby and selenium. Installation of rvm Installation of specific version of ruby and setting a default version of ruby Note: Using a linux based operating system.
6
votes
2answers
4k views

How to specify a higher ruby version for installing a gem?

I install a ruby package. $ sudo gem install pdfbeads ERROR: Error installing pdfbeads: nokogiri requires Ruby version >= 1.9.2. says that it needs ruby version greater than 1.9.1. My ...
2
votes
1answer
993 views

Running shell script inside with vagrant provision

I have setup a vagrant box using precise64 (ubuntu 14.04) and installed packages needed for octopress. I can ssh into the vagrant box and generate posts and run preview for my octopress site. Now I ...
0
votes
3answers
490 views

Why does passing a HEREDOC as a string to `ruby -e` not work?

For reasons I don't understand, it seems to be impossible to pass a heredoc as an expression to a Ruby interpreter: $ ruby -e <<END heredoc> puts 'hi' heredoc> END ruby: no code ...
0
votes
0answers
129 views

Unable to log into Heroku: syntax error, unexpected

I'm new to Heroku. After downloading the script and installing I get an error when I try to login: $ wget -qO- https://toolbelt.heroku.com/install.sh | sh This script requires superuser access to ...
1
vote
1answer
491 views

Can't find rbenv after installation

I've been trying to install rbenv on my fresh Debian 7.4 install, per the instructions here. I follow all the steps on the guide, and they all work fine: I can use rbenv to install Rubies and gems ...
3
votes
2answers
315 views

Time running a Ruby script is different locally than over SSH

Has anyone else seen this behavior? I created a simple Ruby script for giggles to see how fast it would count up on a couple machines I have. Here's the source: for n in 1...1000000 do ...
1
vote
1answer
177 views

How can I add autocomplete for “gem which” with rbenv?

I am using rbenv on Mac OS X. I have autocomplete functionality already for the gem command: $ gem build environment lock query stale cert fetch ...
0
votes
2answers
1k views

Installing ruby 2.1 on Arch via RVM

I have problems installing ruby 2.1.0 via RVM on Arch. My vagrant provisioning file looks like this: sudo pacman -Syu --noconfirm sudo pacman -S --needed base-devel --noconfirm sudo pacman -S vim ...
0
votes
0answers
181 views

Is there a difference between `command rspec` and `rspec`?

I want to call bundle exec rspec if Gemfile exists in current directory, and if it doesn't exists, call rspec itself. So I wrote like this. function rspec() { if [ -e 'Gemfile' ]; then echo ...