Deploying Rails Application in a restricted server - ruby-on-rails

I am trying to deploying my rails application to a restricted server. And I am not able to install ruby and gems from the open internet because the server is restricted in the network. That server is new it dont have any needful library, database and apache to deploying the app. Please provide me the best way to get all the library and needful gems to keep the app running.

Related

Building a server to host rails app locally

I want to know how to build a rails server and host an app on it locally. I know I can use heroku or aws but in the case of this app I can’t, the database should be hosted locally in the company for security reasons; they do not want to store their data on servers that are not theirs.
How do I start?
What are the main things to consider?
Do I host on heroku and link the local database to the site or do I host them all in the same place?
How much power does the machine need for around 10-20k users?
What OS should I use Ubuntu or what?
Would really appreciate if you have any tutorials or article links.
You can just use ngrok. It doesn't require any side server deployments.

Deploying Ruby On Rails app on macOS Server

So lately, I offer myself a Mac Mini which I want to use as a server (Websites, caching, Xcode Server (which is not working), VPN (which is not working), and stuff). Currently it is running macOS Sierra (10.12.4) with Server.app (5.3) installed. I've successfully enabled Websites & DNS service so my server is accessible from the outside. I have a trusted and valid SSL certificate.
The problem is...
...I don't know how to setup the server to be a production server for Ruby On Rails.
Want I want
To host a web app using Ruby On Rails on macOS server (www.example.com)
To know how to setup the server app to serve a web app
To host a Git repository for the web app code
I looked at the settings for Websites service in the Server app but I didn't find any options for other than PHP and Python.
What I know
My MacBook is already setup with Ruby 2.4 and Rails 5.0. I know how to install Rails for development purpose
Even if it's not straight-forward, post any help you have.
One of my guesses is that I could forward the port opened for the website without specifying a folder where the files are in the Server app.
I'd be pleased of you inlight in some way to achieve my goal.
I am pretty sure that you don't want to actually run production off of your mac mini. That said once you have your rails app running you can run rails s to run your server locally. If you want a production site you should look into either heroku or AWS elastic beanstalk for deployment.

Using a Rails JSON API as a backend for desktop app

My company is wanting to use a Rails JSON API app as a backend for a desktop app. The Rails JSON API would use a Postgresql database.
However, some customers self host their data, meaning they have a postgresql server installed on a computer the desktop app uses. Because of these users, we would have to deploy this Rails app and customers would have to run the Rails API server on their machines, including Windows machines. Is this a good idea or even possible?
If your customers are running the db themselves, you probably don't need an api, right?
Otoh, there are tools like portable ruby by the phusion team that let you pacakge up a Ruby app. You can also build the app via JRuby as a jar or war and deploy that in any env with Java

Can i host a rails app via hostgator and FTP

Can you deploy a ruby on rails application to hostgator via FTP. if you Can, Can you guys please Tel me how i do it :) do you have to put something inside your project or is there another Way to host via hostgator?
Greetings from Ludvig.
Any kind of help would be greatly appreciated :)
If you buy hostgator VPS you can deploy rails application. You can not deploy your rails app (like version 4) on the Shared hosting of hostgator.
FTP is not important issue. You can upload your source code via FTP or other way like cloning from git repo. To deploy the rails app your hosting server must install Rails, Ruby and other packages.

Setting up Rails on Hostmonster

I'm able to run rails s through ssh successfully and see the app start up just as it does on my own machine but I'm unable to access the app from the web. The app is directly under the home folder and I have a symbolic link pointing from public_html to the public folder of my rails app, just as this tutorial explains. I even tried setting up a subdomain and every other step in the tutorial to no avail. Any help would be highly appreciated.
You need an application server like Phusion Passenger, Unicorn or puma to run a Ruby app in a production environment. Typically, you'll integrate the application server into a web server's (Apache, nginx) environment.
I don't know about your hoster, but if you have root access, then you can probably use any of these application servers.
The built-in server you start by running rails server is only meant for testing purposes on your local machine. It has not been made with security, performance, stability or any other production-environment criteria in mind.

Resources