Im super new to rails development and am following a basic rails tutorial to get started. I have successfully install rails and ruby on my windows 10, but for some reason the server does not work. I have tried different versions of rails and every time I get a different error. Here is the error message I keep receiving. Any help will be extremely be appreciated. Thank you.
$ rails s
C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/resolver.rb:396:in block in verify_gemfile_dependencies_are_found!': Could not find gem 'tzinfo-data x86-mingw32' in any of the gem sources listed in your Gemfile. (Bundler::GemNotFound)
each’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/resolver.rb:366:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/resolver.rb:366:in verify_gemfile_dependencies_are_found!'
start’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/resolver.rb:212:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/resolver.rb:191:in resolve'
resolve’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/definition.rb:235:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/definition.rb:159:in specs'
specs_for’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/definition.rb:218:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/definition.rb:207:in requested_specs'
block in definition_method’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/runtime.rb:109:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/runtime.rb:21:in setup'
setup’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler.rb:101:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/gems/2.3.0/gems/bundler-1.15.3/lib/bundler/setup.rb:19:in <top (required)>'
require’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:127:in
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:127:in rescue in require'
require’
from C:/RailsInstaller/Ruby2.3.3/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:40:in
from C:/Sites/myarticles/config/boot.rb:3:in <top (required)>'
require_relative’
from bin/rails:3:in
from bin/rails:3:in `’
Here is the Gemfile
source 'https://rubygems.org'
git_source(:github) do |repo_name|
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
"https://github.com/#{repo_name}.git"
end
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.1.3'
# Use sqlite3 as the database for Active Record
gem 'mysql2'
# Use Puma as the app server
gem 'puma', '~> 3.7'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
# gem 'jbuilder', '~> 2.5'
# Use Redis adapter to run Action Cable in production
# gem 'redis', '~> 3.0'
# Use ActiveModel has_secure_password
# gem 'bcrypt', '~> 3.1.7'
# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development
# Use Rack CORS for handling Cross-Origin Resource Sharing (CORS), making cross-origin AJAX possible
# gem 'rack-cors'
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
end
group :development do
end
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
2
Answers
Please do following, but share Gemfile also, as error message is saying Gem not found.
First install ssl_certificate into your ssl_certificate directory of railsinstller. You can following this url
Now use following command to update
Now go to your rails project folder and run following command
Also check you have installed node, npm and yarn. If still error persist make sure all installation of node done.
I have the same problem with you, when I need to run
The alert was coming like
The default on my Gemfile
I remove "platforms: [:mingw, :mswin, :x64_mingw, :jruby]", then my Gemfile like this
After that run
It’s work on my Windows 10