add VirtualMachine resource
[arvados.git] / services / api / db / schema.rb
1 # encoding: UTF-8
2 # This file is auto-generated from the current state of the database. Instead
3 # of editing this file, please use the migrations feature of Active Record to
4 # incrementally modify your database, and then regenerate this schema definition.
5 #
6 # Note that this schema.rb definition is the authoritative source for your
7 # database schema. If you need to create the application database on another
8 # system, you should be using db:schema:load, not running all the migrations
9 # from scratch. The latter is a flawed and unsustainable approach (the more migrations
10 # you'll amass, the slower it'll run and the greater likelihood for issues).
11 #
12 # It's strongly recommended to check this file into your version control system.
13
14 ActiveRecord::Schema.define(:version => 20130608053730) do
15
16   create_table "api_client_authorizations", :force => true do |t|
17     t.string   "api_token",               :null => false
18     t.integer  "api_client_id",           :null => false
19     t.integer  "user_id",                 :null => false
20     t.string   "created_by_ip_address"
21     t.string   "last_used_by_ip_address"
22     t.datetime "last_used_at"
23     t.datetime "expires_at"
24     t.datetime "created_at"
25     t.datetime "updated_at"
26     t.string   "default_owner"
27   end
28
29   add_index "api_client_authorizations", ["api_client_id"], :name => "index_api_client_authorizations_on_api_client_id"
30   add_index "api_client_authorizations", ["api_token"], :name => "index_api_client_authorizations_on_api_token", :unique => true
31   add_index "api_client_authorizations", ["expires_at"], :name => "index_api_client_authorizations_on_expires_at"
32   add_index "api_client_authorizations", ["user_id"], :name => "index_api_client_authorizations_on_user_id"
33
34   create_table "api_clients", :force => true do |t|
35     t.string   "uuid"
36     t.string   "owner"
37     t.string   "modified_by_client"
38     t.string   "modified_by_user"
39     t.datetime "modified_at"
40     t.string   "name"
41     t.string   "url_prefix"
42     t.datetime "created_at"
43     t.datetime "updated_at"
44   end
45
46   add_index "api_clients", ["created_at"], :name => "index_api_clients_on_created_at"
47   add_index "api_clients", ["modified_at"], :name => "index_api_clients_on_modified_at"
48   add_index "api_clients", ["uuid"], :name => "index_api_clients_on_uuid", :unique => true
49
50   create_table "authorized_keys", :force => true do |t|
51     t.string   "uuid",               :null => false
52     t.string   "owner",              :null => false
53     t.string   "modified_by_client"
54     t.string   "modified_by_user"
55     t.datetime "modified_at"
56     t.string   "name"
57     t.string   "key_type"
58     t.string   "authorized_user"
59     t.text     "public_key"
60     t.datetime "expires_at"
61     t.datetime "created_at"
62     t.datetime "updated_at"
63   end
64
65   add_index "authorized_keys", ["authorized_user", "expires_at"], :name => "index_authorized_keys_on_authorized_user_and_expires_at"
66   add_index "authorized_keys", ["uuid"], :name => "index_authorized_keys_on_uuid", :unique => true
67
68   create_table "collections", :force => true do |t|
69     t.string   "locator"
70     t.string   "owner"
71     t.datetime "created_at"
72     t.string   "modified_by_client"
73     t.string   "modified_by_user"
74     t.datetime "modified_at"
75     t.string   "portable_data_hash"
76     t.string   "name"
77     t.integer  "redundancy"
78     t.string   "redundancy_confirmed_by_client"
79     t.datetime "redundancy_confirmed_at"
80     t.integer  "redundancy_confirmed_as"
81     t.datetime "updated_at"
82     t.string   "uuid"
83     t.text     "manifest_text"
84   end
85
86   add_index "collections", ["created_at"], :name => "index_collections_on_created_at"
87   add_index "collections", ["modified_at"], :name => "index_collections_on_modified_at"
88   add_index "collections", ["uuid"], :name => "index_collections_on_uuid", :unique => true
89
90   create_table "commit_ancestors", :force => true do |t|
91     t.string   "repository_name"
92     t.string   "descendant",                         :null => false
93     t.string   "ancestor",                           :null => false
94     t.boolean  "is",              :default => false, :null => false
95     t.datetime "created_at"
96     t.datetime "updated_at"
97   end
98
99   add_index "commit_ancestors", ["descendant", "ancestor"], :name => "index_commit_ancestors_on_descendant_and_ancestor", :unique => true
100
101   create_table "commits", :force => true do |t|
102     t.string   "repository_name"
103     t.string   "sha1"
104     t.string   "message"
105     t.datetime "created_at"
106     t.datetime "updated_at"
107   end
108
109   add_index "commits", ["repository_name", "sha1"], :name => "index_commits_on_repository_name_and_sha1", :unique => true
110
111   create_table "groups", :force => true do |t|
112     t.string   "uuid"
113     t.string   "owner"
114     t.datetime "created_at"
115     t.string   "modified_by_client"
116     t.string   "modified_by_user"
117     t.datetime "modified_at"
118     t.string   "name"
119     t.text     "description"
120     t.datetime "updated_at"
121   end
122
123   add_index "groups", ["created_at"], :name => "index_groups_on_created_at"
124   add_index "groups", ["modified_at"], :name => "index_groups_on_modified_at"
125   add_index "groups", ["uuid"], :name => "index_groups_on_uuid", :unique => true
126
127   create_table "job_tasks", :force => true do |t|
128     t.string   "uuid"
129     t.string   "owner"
130     t.string   "modified_by_client"
131     t.string   "modified_by_user"
132     t.datetime "modified_at"
133     t.string   "job_uuid"
134     t.integer  "sequence"
135     t.text     "parameters"
136     t.text     "output"
137     t.float    "progress"
138     t.boolean  "success"
139     t.datetime "created_at"
140     t.datetime "updated_at"
141     t.string   "created_by_job_task"
142     t.integer  "qsequence",           :limit => 8
143   end
144
145   add_index "job_tasks", ["created_at"], :name => "index_job_tasks_on_created_at"
146   add_index "job_tasks", ["job_uuid"], :name => "index_job_tasks_on_job_uuid"
147   add_index "job_tasks", ["modified_at"], :name => "index_job_tasks_on_modified_at"
148   add_index "job_tasks", ["sequence"], :name => "index_job_tasks_on_sequence"
149   add_index "job_tasks", ["success"], :name => "index_job_tasks_on_success"
150   add_index "job_tasks", ["uuid"], :name => "index_job_tasks_on_uuid", :unique => true
151
152   create_table "jobs", :force => true do |t|
153     t.string   "uuid"
154     t.string   "owner"
155     t.string   "modified_by_client"
156     t.string   "modified_by_user"
157     t.datetime "modified_at"
158     t.string   "submit_id"
159     t.string   "script"
160     t.string   "script_version"
161     t.text     "script_parameters"
162     t.string   "cancelled_by_client"
163     t.string   "cancelled_by_user"
164     t.datetime "cancelled_at"
165     t.datetime "started_at"
166     t.datetime "finished_at"
167     t.boolean  "running"
168     t.boolean  "success"
169     t.string   "output"
170     t.datetime "created_at"
171     t.datetime "updated_at"
172     t.string   "priority"
173     t.string   "is_locked_by"
174     t.string   "log"
175     t.text     "tasks_summary"
176     t.text     "resource_limits"
177   end
178
179   add_index "jobs", ["created_at"], :name => "index_jobs_on_created_at"
180   add_index "jobs", ["finished_at"], :name => "index_jobs_on_finished_at"
181   add_index "jobs", ["modified_at"], :name => "index_jobs_on_modified_at"
182   add_index "jobs", ["output"], :name => "index_jobs_on_output"
183   add_index "jobs", ["script"], :name => "index_jobs_on_script"
184   add_index "jobs", ["started_at"], :name => "index_jobs_on_started_at"
185   add_index "jobs", ["submit_id"], :name => "index_jobs_on_submit_id", :unique => true
186   add_index "jobs", ["uuid"], :name => "index_jobs_on_uuid", :unique => true
187
188   create_table "keep_disks", :force => true do |t|
189     t.string   "uuid",                                 :null => false
190     t.string   "owner",                                :null => false
191     t.string   "modified_by_client"
192     t.string   "modified_by_user"
193     t.datetime "modified_at"
194     t.string   "ping_secret",                          :null => false
195     t.string   "node_uuid"
196     t.string   "filesystem_uuid"
197     t.integer  "bytes_total"
198     t.integer  "bytes_free"
199     t.boolean  "is_readable",        :default => true, :null => false
200     t.boolean  "is_writable",        :default => true, :null => false
201     t.datetime "last_read_at"
202     t.datetime "last_write_at"
203     t.datetime "last_ping_at"
204     t.datetime "created_at"
205     t.datetime "updated_at"
206     t.string   "service_host"
207     t.integer  "service_port"
208     t.boolean  "service_ssl_flag"
209   end
210
211   add_index "keep_disks", ["filesystem_uuid"], :name => "index_keep_disks_on_filesystem_uuid"
212   add_index "keep_disks", ["last_ping_at"], :name => "index_keep_disks_on_last_ping_at"
213   add_index "keep_disks", ["node_uuid"], :name => "index_keep_disks_on_node_uuid"
214   add_index "keep_disks", ["service_host", "service_port", "last_ping_at"], :name => "keep_disks_service_host_port_ping_at_index"
215   add_index "keep_disks", ["uuid"], :name => "index_keep_disks_on_uuid", :unique => true
216
217   create_table "links", :force => true do |t|
218     t.string   "uuid"
219     t.string   "owner"
220     t.datetime "created_at"
221     t.string   "modified_by_client"
222     t.string   "modified_by_user"
223     t.datetime "modified_at"
224     t.string   "tail_uuid"
225     t.string   "tail_kind"
226     t.string   "link_class"
227     t.string   "name"
228     t.string   "head_uuid"
229     t.text     "properties"
230     t.datetime "updated_at"
231     t.string   "head_kind"
232   end
233
234   add_index "links", ["created_at"], :name => "index_links_on_created_at"
235   add_index "links", ["head_kind"], :name => "index_links_on_head_kind"
236   add_index "links", ["head_uuid"], :name => "index_links_on_head_uuid"
237   add_index "links", ["modified_at"], :name => "index_links_on_modified_at"
238   add_index "links", ["tail_kind"], :name => "index_links_on_tail_kind"
239   add_index "links", ["tail_uuid"], :name => "index_links_on_tail_uuid"
240   add_index "links", ["uuid"], :name => "index_links_on_uuid", :unique => true
241
242   create_table "logs", :force => true do |t|
243     t.string   "uuid"
244     t.string   "owner"
245     t.string   "modified_by_client"
246     t.string   "modified_by_user"
247     t.string   "object_kind"
248     t.string   "object_uuid"
249     t.datetime "event_at"
250     t.string   "event_type"
251     t.text     "summary"
252     t.text     "info"
253     t.datetime "created_at"
254     t.datetime "updated_at"
255     t.datetime "modified_at"
256   end
257
258   add_index "logs", ["created_at"], :name => "index_logs_on_created_at"
259   add_index "logs", ["event_at"], :name => "index_logs_on_event_at"
260   add_index "logs", ["event_type"], :name => "index_logs_on_event_type"
261   add_index "logs", ["modified_at"], :name => "index_logs_on_modified_at"
262   add_index "logs", ["object_kind"], :name => "index_logs_on_object_kind"
263   add_index "logs", ["object_uuid"], :name => "index_logs_on_object_uuid"
264   add_index "logs", ["summary"], :name => "index_logs_on_summary"
265   add_index "logs", ["uuid"], :name => "index_logs_on_uuid", :unique => true
266
267   create_table "nodes", :force => true do |t|
268     t.string   "uuid"
269     t.string   "owner"
270     t.datetime "created_at"
271     t.string   "modified_by_client"
272     t.string   "modified_by_user"
273     t.datetime "modified_at"
274     t.integer  "slot_number"
275     t.string   "hostname"
276     t.string   "domain"
277     t.string   "ip_address"
278     t.datetime "first_ping_at"
279     t.datetime "last_ping_at"
280     t.text     "info"
281     t.datetime "updated_at"
282   end
283
284   add_index "nodes", ["created_at"], :name => "index_nodes_on_created_at"
285   add_index "nodes", ["hostname"], :name => "index_nodes_on_hostname"
286   add_index "nodes", ["modified_at"], :name => "index_nodes_on_modified_at"
287   add_index "nodes", ["slot_number"], :name => "index_nodes_on_slot_number", :unique => true
288   add_index "nodes", ["uuid"], :name => "index_nodes_on_uuid", :unique => true
289
290   create_table "pipeline_instances", :force => true do |t|
291     t.string   "uuid"
292     t.string   "owner"
293     t.datetime "created_at"
294     t.string   "modified_by_client"
295     t.string   "modified_by_user"
296     t.datetime "modified_at"
297     t.string   "pipeline_template_uuid"
298     t.string   "name"
299     t.text     "components"
300     t.boolean  "success"
301     t.boolean  "active",                 :default => false
302     t.datetime "updated_at"
303     t.text     "properties"
304   end
305
306   add_index "pipeline_instances", ["created_at"], :name => "index_pipeline_instances_on_created_at"
307   add_index "pipeline_instances", ["modified_at"], :name => "index_pipeline_instances_on_modified_at"
308   add_index "pipeline_instances", ["uuid"], :name => "index_pipeline_instances_on_uuid", :unique => true
309
310   create_table "pipeline_templates", :force => true do |t|
311     t.string   "uuid"
312     t.string   "owner"
313     t.datetime "created_at"
314     t.string   "modified_by_client"
315     t.string   "modified_by_user"
316     t.datetime "modified_at"
317     t.string   "name"
318     t.text     "components"
319     t.datetime "updated_at"
320   end
321
322   add_index "pipeline_templates", ["created_at"], :name => "index_pipeline_templates_on_created_at"
323   add_index "pipeline_templates", ["modified_at"], :name => "index_pipeline_templates_on_modified_at"
324   add_index "pipeline_templates", ["uuid"], :name => "index_pipeline_templates_on_uuid", :unique => true
325
326   create_table "specimens", :force => true do |t|
327     t.string   "uuid"
328     t.string   "owner"
329     t.datetime "created_at"
330     t.string   "modified_by_client"
331     t.string   "modified_by_user"
332     t.datetime "modified_at"
333     t.string   "material"
334     t.datetime "updated_at"
335     t.text     "properties"
336   end
337
338   add_index "specimens", ["created_at"], :name => "index_specimens_on_created_at"
339   add_index "specimens", ["modified_at"], :name => "index_specimens_on_modified_at"
340   add_index "specimens", ["uuid"], :name => "index_specimens_on_uuid", :unique => true
341
342   create_table "users", :force => true do |t|
343     t.string   "uuid"
344     t.string   "owner"
345     t.datetime "created_at"
346     t.string   "modified_by_client"
347     t.string   "modified_by_user"
348     t.datetime "modified_at"
349     t.string   "email"
350     t.string   "first_name"
351     t.string   "last_name"
352     t.string   "identity_url"
353     t.boolean  "is_admin"
354     t.text     "prefs"
355     t.datetime "updated_at"
356     t.string   "default_owner"
357   end
358
359   add_index "users", ["created_at"], :name => "index_users_on_created_at"
360   add_index "users", ["modified_at"], :name => "index_users_on_modified_at"
361   add_index "users", ["uuid"], :name => "index_users_on_uuid", :unique => true
362
363   create_table "virtual_machines", :force => true do |t|
364     t.string   "uuid",               :null => false
365     t.string   "owner",              :null => false
366     t.string   "modified_by_client"
367     t.string   "modified_by_user"
368     t.datetime "modified_at"
369     t.string   "hostname"
370     t.datetime "created_at"
371     t.datetime "updated_at"
372   end
373
374   add_index "virtual_machines", ["hostname"], :name => "index_virtual_machines_on_hostname"
375   add_index "virtual_machines", ["uuid"], :name => "index_virtual_machines_on_uuid", :unique => true
376
377 end