[chef] Re: Re: Re: java::oracle recipe broken due to oracle now requiring browser cookie


Chronological Thread 
  • From: Ranjib Dey < >
  • To:
  • Subject: [chef] Re: Re: Re: java::oracle recipe broken due to oracle now requiring browser cookie
  • Date: Wed, 28 Mar 2012 00:30:46 +0530

agreed ,
and also on the same line, i have faced similar requirements for different use cases where simple get/post functionality is needed for publishing / grabbing build artifacts, custom rpms etc, but since  chef is not meant to be a file server, i use a dedicated nginx instance(or apache ) to do this. It might not make sense for a single use case, but if you have multiple uses cases then it better to have a dedicated file server (http or nfs or webdav  based) for service files and then leverage them using the remote_file/http_request resource.


On Wed, Mar 28, 2012 at 12:14 AM, Adam Jacob < "> > wrote:
Seems like a great reason to move to OpenJDK. My instinct would be that if they are going to this kind of length to get you to register/use a cookie, honor their request - by downloading it locally and fetching it repeatably from a local location. Or by moving to OpenJDK. 

Adam


On Tue, Mar 27, 2012 at 4:25 AM, Bryan Berry < " target="_blank"> > wrote:
besides having your own local copy of java, I have found a way to download directly from oracle.com but it is quite heavyweight. It requires the installation of firefox, Xvfb (virtual X11 server), and the watir-webdriver and headless gems. There is no way around installing firefox as the oracle site requires _javascript_ to agree to their terms.

I am really wondering if this solution is so invasive that no one will use it. If someone has a better solution, pls let me know!



$ sudo apt-get install xvfb

$ gem install watir-webdriver headless


# downloads jdk 1.7
require 'watir-webdriver'
require 'headless'
headless = Headless.
new
headless.start

profile = "Selenium::WebDriver::Firefox::Profile.new
profile['browser.download.folderList'] = 2
profile['browser.download.dir'] = '/tmp'
profile['browser.helperApps.neverAsk.saveToDisk'] = "application/x-tar-gz, application/x-gzip, application/x-compressed"
b = Watir::Browser.new :firefox, :profile =">" profile
b.radio(:name => "agreementDivjdk-7u3-oth-JPR").click
b.radio(:name => "agreementjdk-7u3-oth-JPR").click
b.a(:name => "jdk-7u3-oth-JPRXXXjdk-7u3-linux-x64.tar.gz").click

# somehow need to block until file totally downloaded
headless.destroy



On Tue, Mar 27, 2012 at 10:10 AM, Bryan Berry < " target="_blank"> > wrote:
in the meantime, you can work around this by downloading the tarball to a local server than then overriding the 
node['java'][jdk']['6']['x86_64']['url']    attribute like this  or in a role

node['java'][jdk']['6']['x86_64']['url'] = 'http://your_local_server/java_tarball.tar.gz' 


On Tue, Mar 27, 2012 at 10:05 AM, Bryan Berry < " target="_blank"> > wrote:
dear fellow chefs,

the java::oracle recipe is now broken as Oracle requires a browser cookie set upon accepting license terms

I will  be working on it

that really chaps my hide





--
Opscode, Inc.
Adam Jacob, Chief Customer Officer
T: (206) 619-7151 E: " target="_blank">




Archive powered by MHonArc 2.6.16.

§