Skip to content

Instantly share code, notes, and snippets.

@ultimateprogramer
Created August 20, 2019 13:00
Show Gist options
  • Select an option

  • Save ultimateprogramer/f9293eb40fc8d903eb468fdf27c71ce1 to your computer and use it in GitHub Desktop.

Select an option

Save ultimateprogramer/f9293eb40fc8d903eb468fdf27c71ce1 to your computer and use it in GitHub Desktop.
Ruby on Rails Docker Container from Scratch - Ubuntu
# Derive an Ubuntu Image
FROM ubuntu:18.04
# Update and Upgrade
RUN apt-get update
RUN apt-get upgrade
# Install base `ruby`
RUN sudo apt install ruby
# Rails installs as a GEM
RUN gem install rails
# This allows us to run the 'rails' command
RUN apt install ruby-railties
# Allows us to use the bundle command
RUN apt install ruby-bundler
# Allows us to install ruby gems with native extensions
RUN apt install ruby-dev
# Typically:
# Install base `ruby`
# sudo apt install ruby
# Rails installs as a GEM
# gem install rails
# This allows us to run the 'rails' command
# sudo apt install ruby-railties
# Allows us to use the bundle command
# sudo apt install ruby-bundler
# Allows us to install ruby gems with native extensions
# sudo apt install ruby-dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment