The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Ruby AutoDeploy

Discussion in 'General Discussion' started by AexiSolutions, Nov 5, 2005.

  1. Hello,

    Over the next few weeks, I have plans in place to completely rebuild my companies virtual hosting offerings, and therefor want to introduce additional features such as RoR support and a dPHP4+5 intertwined setup.

    Looking at the deployment of Ruby, I can see the actual installation appears to be pretty simple and am able to get Ruby running on a test box here. However, I want to somehow setup cPanel so Ruby is automatically available on newly created accounts and preferably existing accounts.

    It has come to my attention, that for rubies to run. You must do something similiar to rails <folder_Name_here>, then a ln -s for the application to be setup and become available via FTP and the web.

    My question is this; is it possible to completely automate the setup of new Ruby applications without the need to prove jail shell to my clients.

    One thing I was contemplating was developing a small cPanel plugin that would use cpwrapper to run the required commands for each application, however, is this really neccessary?.

    Your input is appreciated.
     
  2. Earendil

    Earendil Well-Known Member

    Joined:
    Jun 10, 2004
    Messages:
    102
    Likes Received:
    0
    Trophy Points:
    16
    Sounds like a job for postwwwacct in /scripts :)
     
  3. PhoenixIgnition

    Joined:
    Nov 5, 2005
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    The initial part yes, however, adding additional applications etc?.

    This is AexiSolutions by the way, my other account got locked out when I tried to change my email.
     
  4. PhoenixIgnition

    Joined:
    Nov 5, 2005
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
  5. Earendil

    Earendil Well-Known Member

    Joined:
    Jun 10, 2004
    Messages:
    102
    Likes Received:
    0
    Trophy Points:
    16
    You mean after the initial creation of an account?
     
  6. PhoenixIgnition

    Joined:
    Nov 5, 2005
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    Correct. Its easy enough to get cPanel to create an initial ruby 'application' on account creation. However, what if they want to create a new application, the only way this is possible is through ssh 'rails /home/blah/folder/name' and I don't want to give out jail/bash access at all.

    I'm extremely suprised companies like Site5 havn't automated this task yet either.

    Suggestions?
     
  7. Earendil

    Earendil Well-Known Member

    Joined:
    Jun 10, 2004
    Messages:
    102
    Likes Received:
    0
    Trophy Points:
    16
    You could make a script which checks a certain file within their accounts every x minutes and does it for them.
    That's all I can come up with.
     
  8. dgbaker

    dgbaker Well-Known Member
    PartnerNOC

    Joined:
    Sep 20, 2002
    Messages:
    2,578
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Toronto, Ontario Canada
    cPanel Access Level:
    DataCenter Provider

    This is one of the things you will need to deal with. There is no harm in giving jailshell access on a properly set up, secured server with proper monitoring. There is a lot more to ruby then just installing and saying "here you can now use it". You have other things like environment variables to deal with, additional modules that may need to be installed. Let alone troubleshooting. I actually have a ruby developer working part-time for us to ensure support is available.

    I personally fear that in the webhosting community RoR will become another tomcat nightmare.
     
  9. rs-freddo

    rs-freddo Well-Known Member

    Joined:
    May 13, 2003
    Messages:
    832
    Likes Received:
    1
    Trophy Points:
    18
    Location:
    Australia
    cPanel Access Level:
    Root Administrator
    As a Programmer and Hosting business I can only say that Aplication Development Environments such as RoR are a big mistake. Generally speaking the ADE supplies a very broad range of subsets, but the programmer only uses a few of the subsets. Yet every time the website is accessed the whole ADE must be loaded into memory. The programmer doesn't care - all they are concerned about is the ability to produce an app quickly. However as a Hosting company I see this approach to application development as a huge mistake. Basically ADE's encourage bloated applications that need lots of resources to run. Personally I prefer to develop apps that run lean and mean.

    If you plan to run Tomcat or RoR as a service to your Hosting customers make sure you are charging a high enough price to compensate for the bloat. These are not offerings for $5 accounts.
     
  10. PhoenixIgnition

    Joined:
    Nov 5, 2005
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    To me freddo, dgbaker, thats a bit of a sweeping statement. Although I agree with the main aspect of your arguement, you seem to be making poor comparisons between the likes of RoR and JDK.

    For one, RoR is not even close to 1/10th as resource intensive as the likes of coldfusion or tomcat. I have been a systems administrator and php programmer now for 5 years and am currently running numerous development servers with php/ruby running hand in hand on all machines.

    One development machine is infact extremely busy and quite a low spec machine, we're talking mhz here not ghz, and the memory is in the region of 300-400MB. Ruby, the primary language on that system currently has 4 active processes and between them is consuming 32mb, which is peanuts compared to the amount available.

    My concern here is not with the actual management of ruby itself, simply with its non-existant intergration with cPanel. I have no interest in offering jail shell, as no matter how secure you may think your system is, there are endless ways even the most secure jail account could be compromised. To me, the risk simply isn't worth the additional functionality.

    If you have no suggestions other than to regurgitate my initial findings, then I see little to no point in a response. I have already mentioned jailshell is not an option and the reasons for it not being so.

    However, if you have a real suggestion that might benefit the topic stated in the OP, you are welcome to make it known.

    Thank you
     
  11. dgbaker

    dgbaker Well-Known Member
    PartnerNOC

    Joined:
    Sep 20, 2002
    Messages:
    2,578
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    Toronto, Ontario Canada
    cPanel Access Level:
    DataCenter Provider
    With comments like this do not expect much help.
     
  12. PhoenixIgnition

    Joined:
    Nov 5, 2005
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    I have resolved this issue myself by developing my own ruby plugin for cpanel anyway, so it is not a problem.

    The responses I have received were far from useful at any rate.

    Feel free to remove / lock this thread as the issue is now resolved
     
  13. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    Phoenix - Can you tell us more about this plugin? Any plans to make it available to others?
     
  14. PhoenixIgnition

    Joined:
    Nov 5, 2005
    Messages:
    6
    Likes Received:
    0
    Trophy Points:
    1
    It allows the creation of applications through cpwrapper, including delete etc.

    I will see about a public release, to be honest. Posts from moderators havn't filled me with the upmost confidence regarding the community round here.

    Like I said though, we'll see.
     
  15. Earendil

    Earendil Well-Known Member

    Joined:
    Jun 10, 2004
    Messages:
    102
    Likes Received:
    0
    Trophy Points:
    16
    You're welcome... I'll try not to attempt to help you anymore.
     
  16. shacker23

    shacker23 Well-Known Member

    Joined:
    Feb 20, 2005
    Messages:
    263
    Likes Received:
    1
    Trophy Points:
    16
    Understood Phoenix. In any case, I'd be curious to give it a spin, if you do decide to release it. I'm getting more requests by the day for Rails support, but want to be sure it's implemented cleanly if I do release it.
     
  17. wmiles

    wmiles Member

    Joined:
    Sep 6, 2005
    Messages:
    21
    Likes Received:
    0
    Trophy Points:
    1
    Did this ever happen or is there any such thing? I'd love it :)
     
Loading...

Share This Page