Skip to content

Instantly share code, notes, and snippets.

@jacksonpires
Last active November 20, 2022 19:59
Show Gist options
  • Save jacksonpires/403ac7e61dfd70e302b1da281decbe15 to your computer and use it in GitHub Desktop.
Save jacksonpires/403ac7e61dfd70e302b1da281decbe15 to your computer and use it in GitHub Desktop.
Vagrantfile Rails configuration
VAGRANTFILE_API_VERSION = '2'
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = '<your>/<box>'
config.ssh.insert_key = false # linha obrigatória para Windows
config.vm.network :forwarded_port, guest: 3000, host: 3000 # rails
config.vm.network :forwarded_port, guest: 9292, host: 9292 # rack
config.vm.network :forwarded_port, guest: 4567, host: 4567 # sinatra
config.vm.network :forwarded_port, guest: 1080, host: 1080 # mailcatcher
config.vm.network :forwarded_port, guest: 8888, host: 8888 # jasmine
config.vm.network :forwarded_port, guest: 3306, host: 3306 # mysql
config.vm.network :forwarded_port, guest: 1234, host: 1234 # node
config.vm.network :forwarded_port, guest: 5432, host: 5432 # postgresql
config.vm.network :forwarded_port, guest: 6379, host: 6379 # redis
config.vm.network :forwarded_port, guest: 9200, host: 9200 # elasticsearch
config.vm.network :forwarded_port, guest: 27017, host: 27017 # mongodb
config.vm.network :forwarded_port, guest: 80, host: 8080 # apache/nginx
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment