Skip to content
This repository has been archived by the owner on Jul 21, 2019. It is now read-only.

RStudio package not found #5

Open
balnagy opened this issue Nov 20, 2013 · 7 comments
Open

RStudio package not found #5

balnagy opened this issue Nov 20, 2013 · 7 comments

Comments

@balnagy
Copy link

balnagy commented Nov 20, 2013

Do you have working apt repo? The installation is failing with the default one and I can't find the package here: http://cran.stat.ucla.edu/bin/linux/ubuntu/lucid/

This instruction says you should download manually: http://www.rstudio.com/ide/download/server

@joestump
Copy link
Contributor

joestump commented Mar 8, 2014

Not sure why I would download something manually when we have something like Chef. 😄

There is a list of mirrors on RStudio's site.

@davidski
Copy link

davidski commented Jun 6, 2014

The list from @joestump only includes the CRAN repositories. I've not found any repo that has the rstudio-server package. I don't know how this workbook could function without it. 😦 It looks like this may need to be re-written to pull the file down from the Rstudio site and install locally.

@joestump
Copy link
Contributor

joestump commented Jun 6, 2014

We use this in production so I know it works, though I do recall having to refactor something recently around this. I'll try and take a peek soon.

@joestump
Copy link
Contributor

joestump commented Jun 6, 2014

I think you guys are right. Not sure how it was working before, but it looks like the rstudio::shiny does do a manual download and install the way that they mention to for the regular server.

@joestump
Copy link
Contributor

joestump commented Jun 6, 2014

case node["platform"].downcase
when "ubuntu", "debian"
    include_recipe "apt"

    package "r-base"

    remote_shiny_server_file = "#{base_download_url}/shiny-server-#{node['rstudio']['shiny']['version']}-#{node['rstudio']['shiny']['arch']}.deb"
    local_shiny_server_file = "/tmp/shiny-server-shiny-server-#{node['rstudio']['shiny']['version']}-#{node['rstudio']['shiny']['arch']}.deb"
    remote_file local_shiny_server_file do
        source remote_shiny_server_file
        action :create_if_missing
        not_if { ::File.exists?('/etc/init/shiny-server.conf') }
    end

    execute "install-shiny-server" do
        command "dpkg --install #{local_shiny_server_file}"
        not_if { ::File.exists?('/etc/init/shiny-server.conf') }
    end

    r_package "shiny"
end

You should be able to change the stanza in recipes/shiny.rb to look similar to the recipes/shiny.rb one above to enable installing the server correctly.

@davidski
Copy link

davidski commented Jun 6, 2014

Thanks, @joestump. I've got a hacked up fork working right now. I'll clean this up and submit a PR when it's slightly less ugly. 😄

@davidski
Copy link

davidski commented Jun 8, 2014

PR request #6 submitted. I'd like to clean this up more (changing the pattern of URL construct, adding in rhel/centos support, etc.) but this is consistent with the shiny recipe and WFM under Ubuntu images. As i will probably need to deploy this on CentOS and AWS Linux, I expect to do another PR for those soon(ish) as well.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

3 participants