sudo apt update-y
sudo apt upgrade-y
gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3
\curl -sSL https://get.rvm.io | bash -s stable --ruby=2.1.5
#!/bin/sh
echo "install ntpdate:"
apt install ntpdate
echo "install nodejs:"
apt install -y nodejs
echo "install unzip:"
apt install -y
# for pg gem
sudo apt install libpq-dev-y
echo "install Java 8 at:"
add-apt-repository ppa:webupd8team/java
apt update
apt install -y oracle-Java 8 at-installer
echo "install postgresql"
apt install -y postgresql
echo "install redis:"
apt install -y redis-server
echo "install git:"
apt install -y git
echo "install imagemagick:"
apt install -y imagemagick
echo "install bundler:"
gem install bundler --no-rdoc --no-ri
echo "install rails 4.2.5:"
gem install rails -v 4.2.5 --no-rdoc --no-ri
echo "install backup 4.2.0:"
gem install backup -v 4.2.0 --no-rdoc --no-ri
echo "install nginx+passenger:"
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7
apt install -y apt-transport-https ca-certificates
# Add our APT repository
sh-c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger xenial main > /etc/apt/sources.list.d/passenger.list'
apt update
# Install Passenger + Nginx
apt install -y nginx-extras passenger
deployer@4e4o:~$ nginx -t
nginx: [alert] could not open error log file: open() "/var/log/nginx/error.log" failed (13: Permission denied)
2016/05/19 20:49:14 [emerg] 13510#13510: unknown directive "passenger_ruby" in /etc/nginx/nginx.conf:14
nginx: configuration file /etc/nginx/nginx.conf test failed
And I really want a new OS))))
sh-c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger xenial main > /etc/apt/sources.list.d/passenger.list'
deployer@4e4o:~$ nginx -t
nginx: [alert] could not open error log file: open() "/var/log/nginx/error.log" failed (13: Permission denied)
config for nginx (good, working, tested on another OS)
unknown directive "passenger_ruby" in /etc/nginx/nginx.conf:14
Find more questions by tags NginxPassengerRuby on RailsUbuntu Server