Permalink
Browse files

Grails from Download grails and unzip.

Installing Ubuntu repo proved too brittle.
  • Loading branch information...
1 parent f15b461 commit f72573fe98fde0003498ef5196c9293e83577849 Tim Redding committed Jun 21, 2012
Showing with 52 additions and 31 deletions.
  1. +5 −1 attributes/default.rb
  2. +31 −0 recipes/default-ubuntu.rb
  3. +16 −30 recipes/default.rb
View
@@ -1 +1,5 @@
-default['groovy']['version'] = "1.8"
+default['grails']['version'] = "2.0.4"
+default['grails']['archive_name'] = "grails-#{node['grails']['version']}.zip"
+default['grails']['source_url'] = "http://dist.springframework.org.s3.amazonaws.com/release/GRAILS/#{node['grails']['archive_name']}"
+default['grails']['install_path'] = "/usr/local/grails-#{node['grails']['version']}"
+default['grails']['owner'] = "vagrant"
View
@@ -0,0 +1,31 @@
+#
+# Cookbook Name:: grails
+# Recipe:: default
+#
+# Copyright 2012, YOUR_COMPANY_NAME
+#
+# All rights reserved - Do Not Redistribute
+#
+
+include_recipe "java"
+
+case node["platform"]
+when "ubuntu"
+ #sudo apt-add-repository ppa:groovy-dev/grails
+ #sudo apt-get update
+ #sudo apt-get install grails
+ package 'python-software-properties'
+ apt_repository "grails" do
+ uri "http://ppa.launchpad.net/groovy-dev/grails/ubuntu "
+ distribution node['lsb']['codename']
+ components ["main"]
+ keyserver "keyserver.ubuntu.com"
+ key "02A9EC29"
+ action :add
+ notifies :run, resources(:execute => "apt-get update"), :immediately
+ end
+end
+
+package "grails-#{node['grails']['version']}" do
+ action :install
+end
View
@@ -1,31 +1,17 @@
-#
-# Cookbook Name:: groovy
-# Recipe:: default
-#
-# Copyright 2012, YOUR_COMPANY_NAME
-#
-# All rights reserved - Do Not Redistribute
-#
-
-include_recipe "java"
-
-case node["platform"]
-when "ubuntu"
- #sudo apt-add-repository ppa:groovy-dev/groovy
- #sudo apt-get update
- #sudo apt-get install groovy
- package 'python-software-properties'
- apt_repository "groovy" do
- uri "http://ppa.launchpad.net/groovy-dev/groovy/ubuntu "
- distribution node['lsb']['codename']
- components ["main"]
- keyserver "keyserver.ubuntu.com"
- key "02A9EC29"
- action :add
- notifies :run, resources(:execute => "apt-get update"), :immediately
- end
-end
-
-package "groovy-#{node['groovy']['version']}" do
- action :install
+#
+# Cookbook Name:: grails
+# Recipe:: default
+#
+# Copyright 2012, YOUR_COMPANY_NAME
+#
+# All rights reserved - Do Not Redistribute
+#
+
+ark "grails" do
+ url "#{node['grails']['source_url']}"
+ version "#{node['grails']['version']}"
+ # checksum "#{node['grails']['checksum']}"
+ owner "#{node['grails']['owner']}"
+ append_env_path true
+ action :install
end

0 comments on commit f72573f

Please sign in to comment.