You’re not receiving notifications from this thread.
Setup Windows 10 Discussion
I installed ruby and rails correctly, but when I run my new rails app, my browser cannot connect. I must have missed something obvious somewhere. Has anyone else had this problem?
Nothing wrong! Just had to start the MySQL service: "sudo service mysql start"
Is there anything wrong with just running `sudo apt install rbenv` instead of the shell script? I was having issues with the script. Only the plugins folder was cloned...
Doesn't work with me.
Don't know how to build task 'v' (see --tasks)
/home/Emad/myapp/bin/rails:9:in `<top (required)="">'
/home/Emad/myapp/bin/spring:15:in `<top (required)="">'
(See full trace by running task with --trace)
Just wanted to let you know that I just got this up and running! Thankfully I didn't have any issues. Thank you to whoever for putting this together! Great job!!!!
Alberto, yep. You'll always need libpq-dev to compile the C extension for Ruby to talk to Postgres. 👍
Hey John, not sure why that command doesn't work from you. I just pasted in the RVM installation instructions from their website. I don't use RVM though but as long as you get the gpg keys imported, that's all you need.
So I got this running a long time ago and haven't had any issues since but now when I run any rails command I get a warning that says:
/home/user/.rbenv/versions 2.5.3/lib/ruby/gems/2.5.0/gems/railities-5.2.2/lib/rails/app_loader.rb:53 warning: Insecurable world writeable dir mnt/c/rails/project
All the stackoverflow answers are to chmod go-w /home/user but this and many derivations of this doesn't work. What else can I try?
@eliot I looked into this a few months ago and just accepted that it wasn't going to go away unless WSL was changed by Microsoft. Details at: https://github.com/Microsoft/WSL/issues/1426.
There appears to be ways to get rid of it but could introduce a security issue... I decided it was probably a bit of OCD on my behalf and to just let it go. I just find chasing these bugs means hours lost where I could actually be writing code. If you do figure out a good way please tell though.
Agreed, one can spend many hours trying to figure out the root cause of why certain things happen. In the end I found a "solution". Within the /mnt/c/ folder I rm -rf the original rails folder and then ran, "mkdir rails_sites, rails new....etc" and by deleting the old dir and creating a new one seems to have worked for the time being. It is strange this is the first time I have had any issues with the linux subsystem. Besides this minor hiccup I have really enjoyed it. I will update if I find anything else.
Hi, im using Windows 10 with the WSL, and im trying to set the Ruby Interpreter in RubyMine to the one i install using Chirs guide, using the following route /home/tensai/.rbenv/shims/ruby, the problem is that when it starts to Loading the Enviorment throws a Communication Error?
Can anyone tell how i can properly set my RubyMine to use the ruby install in WSL? using rbenv as the version manager.
Hey having a hard time debugging an error maybe someone has some insight?
gem install bundler Fetching bundler-2.0.1.gem /home/dj/.rbenv/rbenv.d/exec/gem-rehash/rubygems_plugin.rb:6: warning: Insecure world writable dir /home/dj/.rbenv/versions in PATH, mode 040777 Successfully installed bundler-2.0.1 Parsing documentation for bundler-2.0.1 Installing ri documentation for bundler-2.0.1 Done installing documentation for bundler after 10 seconds 1 gem installed
this insecure world writeable dir has been plaguing me if I try to set up a DB and run
rake db:create or
rails db:create it wont allow it to do anything any help is appriciated!
Hey Chris I'm getting the following error:
PG::ConnectionBad (could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"?
Hi, can anyone help me with a problem, I'm using windows 10 I have installed ruby, Ubuntu and WSL. Whenever I run my code in visual studio editor or console, I receive this warning message,
warning: Insecure world writable dir /mnt/c in PATH, mode 040777
Is there any way I can fix the problem?
i have the same problem:
i tried an older version of bundler still no change.
then i've seen this :
gem install bundler -v 2.0.1
Fetching: bundler-2.0.1.gem (100%)
/home/cod/.rbenv/rbenv.d/exec/gem-rehash/rubygems_plugin.rb:6: warning: Insecure world writable dir /home/cod/.rbenv/versions/2.5.7 in PATH, mode 040777
Successfully installed bundler-2.0.1
Parsing documentation for bundler-2.0.1
Installing ri documentation for bundler-2.0.1
Done installing documentation for bundler after 5 seconds
1 gem installed
so i think that your solution chmod +t -R ~/.bundle is not good in my case,
chmod: cannot access '/home/cod/.bundle': No such file or directory
any idea for an work around?
when I do 'cd'=> and after 'pwd' => home/user_name,
therefore should i change the commands from:
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
echo 'export PATH="$HOME/user_name/.rbenv/bin:$PATH"' >> ~/.bashrc
echo 'eval "$(rbenv init -)"' >> ~/.bashrc
Hey there! This guide was VERY useful, as every other guide on the subject I found had untold errors along the way. This one worked perfectly, up one of the very last steps after installing postgresql, where you select it using this:
rails new myapp -d postgresql
I receive this error:
/home/event/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/railties-6.0.1/lib/rails/app_loader.rb:53: warning: Insecure world writable dir /home/event/.rbenv/versions/2.6.5 in PATH, mode 040777 sh: 1: node: not found sh: 1: nodejs: not found Node.js not installed. Please download and install Node.js https://nodejs.org/en/download/
I installed NodeJS, but I'm still receiving this error. I tried to proceed to the next part regardless, but on this portion of code:
I receive this error:
could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"? Couldn't create 'myapp_development' database. Please check your configuration. rake aborted! ActiveRecord::NoDatabaseError: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"? Caused by: PG::ConnectionBad: could not connect to server: No such file or directory Is the server running locally and accepting connections on Unix domain socket "/var/run/postgresql/.s.PGSQL.5432"? Tasks: TOP => db:create (See full trace by running task with --trace)
Apologies for the long help request! I'm just starting out in coding, and getting my development environment set up on Windows is taking a good chunk of my time by itself unfortunately.