I connect via ssh to an OVH hosting, I manage to connect but the problem is that I cannot execute any ubuntu command when I try to install ruby and rails on my server. I am new to ssh ...
formasm@cloudweb-ssh:~ $ sudo su
-bash: sudo: command not found
formasm@cloudweb-ssh:~ $ apt-get update
Reading package lists... Done
E: List directory /var/lib/apt/lists/partial is missing. - Acquire (13: Permission denied)
formasm@cloudweb-ssh:~ $ sudo apt-get update
-bash: sudo: command not found
Thank you for your help.
On OVH Hosting Cloud Web
offers, you don't have access to the sudo
command nor to the root
user: as this is a managed offer, you don't have the administrator rights.
However, it's totally possible to install Ruby on Rails
, as Cloud Web provide dependency manager for different languages (gem
and bundle
for Ruby; npm
and yarn
for NodeJS etc.).
To install Ruby on Rails
on OVH's Cloud Web
:
jeanmim@cloudweb-ssh:~ $ export PATH=$PATH:/usr/local/ruby2.6/bin:~/.gem/ruby/2.6.0/bin
jeanmim@cloudweb-ssh:~ $ export GEM_HOME=~/.gem/ruby/2.6.0
jeanmim@cloudweb-ssh:~ $ gem install rails --user --no-doc
Fetching thread_safe-0.3.6.gem
Fetching concurrent-ruby-1.1.6.gem
Fetching i18n-1.8.2.gem
Fetching zeitwerk-2.3.0.gem
....
jeanmim@cloudweb-ssh:~ $ bundle install
Fetching gem metadata from https://rubygems.org/.........
Fetching gem metadata from https://rubygems.org/.
Resolving dependencies.....
Using rake 12.3.2
Using concurrent-ruby 1.1.5
....
You can find a documentation here about how to install a Ruby app on a Cloud Web
hosting: https://docs.ovh.com/fr/cloud-web/installer-camaleon-cloud-web/ (in french only from what I can see)