-
Notifications
You must be signed in to change notification settings - Fork 49
Prax does not use app gemsets #77
Comments
pull request: #78 |
Could you switch to the |
Thanks, I will give that a shot this evening. |
If I get it working I could add something to the readme. |
I changed to unstable and this is what I have in my .praxconfig and it still isn't working.
Here is the log.
|
it should be using a gemset called pricer. |
This also doesn't work for the praxconfig. It seems to be because the present working directory at the point of it running is the home directory instead of the app directory so it isn't going to load the rvm files. Going to look into it further later.
|
That being said there is #73 about the cleanup of environment variables; maybe some gems and version managers need more environment variables than the very few I let slip by (ie. almost none). |
Great, I will probably take a second stab at this too. Just in case you didn't have this, here is a powrc file that I got working on my mac partition today. It is a bit complex since it has backwards compatibility. if [ -f "$rvm_path/scripts/rvm" ]; then
source "$rvm_path/scripts/rvm"
if [ -f ".rvmrc" ]; then
source ".rvmrc"
else
if [ -f ".ruby-version" ]; then
if [ -f ".ruby-gemset" ]; then
rvm use `cat .ruby-version`@`cat .ruby-gemset`
else
rvm use `cat .ruby-version`
fi
fi
fi
fi |
Nice! But you must set it up for every projects, right? That's cumbersome :( |
Yeah, maybe FileUtils.copy('/prax_path/premade_praxrc', '/app_path/.praxrc') unless File.exists?('/app_path/.praxrc') |
I'm on Ubuntu 13.10. I used the .praxconfig that @kwstannard provided but it didn't work. I had to add |
@MDCore glad I could help someone. I have rvm_path set automagically somehow. |
Could some one write briefly how to set this up, which branch and what .praxconfig lines? I have tried every branch with all sorts of different configurations and it still does not work. According to the log files, my rvm ruby binary is not the first in the $PATH variable. How would I accomplish that? I modified the $PATH definition in .praxconfig but that was ignored... |
@helmerj This is my .praxconfig
The important line for me was |
It still wont work :-( Here is what I do (as a regular user):
When I then restart my browser and go to http://myapp.dev (myapp replaced the correct name of my link in ~/prax) I get a DNS error and chrome cannot connect to myapp.dev. I have tried to restart the prax service and stopped the background job using prax stop && prax start which outputs the echo lines from ~/.praxconfig. There is no _log directory created in ~/.prax so I am afraid the service is actually not working at all! Clueless on this one. :-( |
@helmerj Are you perhaps running apache? I have to |
@MDCore I am running nginx on port 80 actually. stopping nginx fixed it! Coolio! Thanks for your help! :-) |
If you don't want to stop nginx you could still use nginx as a proxy to prax, using a config like this: https://github.com/ysbaddaden/prax/wiki/Alternate-setup#nginx |
Ever since the merge of unstable into master (release of version 0.1.0) the ~/.praxconfig file is ignored and my rvm setup does not work anymore. :-( After a fresh install:
How can I make sure the service is even running? |
Please try to run Prax with |
Coolio! Ever since I started the service with the debug var and foreground flag it works again. Even without them flags. Before I had re-installed rebooted several times and it didn't. Don't know why but on't care as well. It works, that makes me happy. Thanks a lot! :-) UPDATE: IF I start prax outside my project's directory the command ignores my ~/.praxconfig file and I cannot start the app using myapp.dev If I start prax inside the project's directory, the ~/.praxconfig file is read and the app can be used under myapp.dev Don't think that is desired behavior is it? |
Then nothing is fixed. This is working when run from project directory because prax will be run using RVM and your project's ruby version, which won't be the case outside (maybe it's the system ruby). Please note that Please run with the PRAX_DEBUG flag and then debug |
The solution posted by @MDCore works for me. I noticed though that when I run
This warning does not appear if I run the same command from any other folder |
As stated in #91 maybe all that's required is to call |
So I tried all from #77 and #91, but the only thing that helped me in the end was:
It works and I do not want to be spending (wasting?) more time on this, and @ysbaddaden - thanks a lot, Prax is really awesome, in particular for demos, but I am one more problem away from uninstalling RVM completely and just using one Ruby at the time... |
I did switch to a single Ruby runtime on a fresh linux install, using my ruby-updates ubuntu ppa and Vagrant boxes for bigger projects (they usually need special software anyway). I'm still using Prax directly for small projects and for port-forwarding to the Vagrant boxes. |
I'm closing the issue. Prax + RVM looks like working. I also created a [[Ruby Version Managers]] page on the Wiki. |
It appears to use the global gemset even if you have an app specific gemset.
Steps to reproduce.
http://sub.testapp.dev
and you should get an error.prax/_logs/testapp.log
The text was updated successfully, but these errors were encountered: