OSDN Git Service

adds PostgreSQL support.
[metasearch/grid-chef-repo.git] / cookbooks / screwdriver / attributes / default.rb
index 4428f3c..beabd24 100644 (file)
@@ -418,6 +418,21 @@ when 'mysql'
       #'MYSQL_DATABASE' => 'screwdriver',
     },
   }
+when 'postgres'
+  version_2_config['services']['db'] = {
+    'image' => 'postgres:9',
+    'volumes' => [
+      # This variable will be set by the screwdriver::docker-compose recipe automatically.
+      #"#{node['screwdriver']['docker-compose']['data_dir']}/postgres:/database:rw",
+    ],
+    'environment' => {
+      # These variables will be set by the screwdriver::docker-compose recipe automatically.
+      #'POSTGRES_USER' => '${DB_USERNAME}',
+      #'POSTGRES_PASSWORD' => '${DB_PASSWORD}',
+      #'POSTGRES_DB' => 'screwdriver',
+      #'PGDATA' => '/database',
+    },
+  }
 end
 
 default['screwdriver']['docker-compose']['config'] = version_2_config