blob: e54932d1c4d82336beb652dff0f737fb0e43f183 [file] [log] [blame]
Michael Lando451a3402017-02-19 10:28:42 +02001template "/tmp/create_dox_keyspace.sh" do
2 source "create_dox_keyspace.sh.erb"
Michael Landoed64b5e2017-06-09 03:19:04 +03003 sensitive true
Michael Lando451a3402017-02-19 10:28:42 +02004 mode 0755
5 variables({
Michael Landoed64b5e2017-06-09 03:19:04 +03006 :cassandra_ip => "HOSTIP",
7 :DC_NAME => node['cassandra'][:cluster_name]+node.chef_environment
Michael Lando451a3402017-02-19 10:28:42 +02008 })
9end
10
Michael Landoed64b5e2017-06-09 03:19:04 +030011
12cookbook_file "/tmp/create_dox_db.cql" do
13 sensitive true
14 source "create_dox_db.cql"
15 mode 0755
16end
17
18cookbook_file "/tmp/alter_dox_db.cql" do
19 sensitive true
20 source "alter_dox_db.cql"
21 mode 0755
22end
23
24
25bash "create-DOX-schema" do
26 ignore_failure true
27 code <<-EOH
28 cd /tmp
29 chmod +x /tmp/create_dox_keyspace.sh
30 /tmp/create_dox_keyspace.sh
31 EOH
32end