]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/foundation/recipes/owg.rb
Switch minutely replication to use osmdbt
[chef.git] / cookbooks / foundation / recipes / owg.rb
index bc239ba1ea3fbdcfa045f179ac38473bb5f0b03a..31d41aa1fdd85c491b6594fe0f2a2ae6fe09a27c 100644 (file)
@@ -21,9 +21,14 @@ include_recipe "apache"
 include_recipe "git"
 
 package %w[
+  gcc
+  g++
+  make
   ruby
   ruby-dev
+  libssl-dev
   zlib1g-dev
+  pkg-config
 ]
 
 gem_package "bundler" do
@@ -32,21 +37,30 @@ end
 
 git "/srv/operations.osmfoundation.org" do
   action :sync
-  repository "git://github.com/openstreetmap/owg-website.git"
+  repository "https://github.com/openstreetmap/owg-website.git"
+  depth 1
   user "root"
   group "root"
   notifies :run, "execute[/srv/operations.osmfoundation.org/Gemfile]"
 end
 
 directory "/srv/operations.osmfoundation.org/_site" do
-  mode 0o755
+  mode "755"
+  owner "nobody"
+  group "nogroup"
+end
+
+# Workaround https://github.com/jekyll/jekyll/issues/7804
+# by creating a .jekyll-cache folder
+directory "/srv/operations.osmfoundation.org/.jekyll-cache" do
+  mode "755"
   owner "nobody"
   group "nogroup"
 end
 
 execute "/srv/operations.osmfoundation.org/Gemfile" do
   action :nothing
-  command "bundle install"
+  command "bundle install --deployment"
   cwd "/srv/operations.osmfoundation.org"
   user "root"
   group "root"
@@ -54,8 +68,7 @@ execute "/srv/operations.osmfoundation.org/Gemfile" do
 end
 
 execute "/srv/operations.osmfoundation.org" do
-  action :nothing
-  command "bundle exec jekyll build --trace --baseurl=https://operations.osmfoundation.org"
+  command "bundle exec jekyll build --trace"
   cwd "/srv/operations.osmfoundation.org"
   user "nobody"
   group "nogroup"