-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathdatabase.sqlite.sql
64 lines (53 loc) · 1.12 KB
/
database.sqlite.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
CREATE TABLE "databases" (
"id" INTEGER PRIMARY KEY AUTOINCREMENT,
"db_name" TEXT,
"db_type" TEXT,
"address" TEXT,
"port" TEXT,
"username" TEXT,
"password" TEXT,
"user_id" TEXT REFERENCES "users"("id"),
"status" TEXT,
"token" TEXT
);
CREATE TABLE "network_configs" (
"id" INTEGER PRIMARY KEY AUTOINCREMENT,
"name" TEXT,
"ssid" TEXT,
"anonymous_id" TEXT,
"username" TEXT,
"password" TEXT,
"probe_id" INTEGER REFERENCES "probes"("id")
);
CREATE TABLE "probes" (
"id" INTEGER PRIMARY KEY AUTOINCREMENT,
"name" TEXT,
"custom_id" TEXT,
"location" TEXT,
"port" INTEGER,
"pub_key" TEXT,
"host_key" TEXT,
"association_period_start" INTEGER,
"associated" INTEGER,
"has_been_updated" INTEGER,
"last_updated" TEXT,
"user_id" INTEGER REFERENCES "users"("id")
);
CREATE TABLE "scripts" (
"id" INTEGER PRIMARY KEY AUTOINCREMENT,
"description" TEXT,
"args" TEXT,
"minute_interval" INTEGER,
"enabled" INTEGER,
"required" INTEGER,
"probe_id" INTEGER REFERENCES "probes"("id")
);
CREATE TABLE "users" (
"id" INTEGER PRIMARY KEY AUTOINCREMENT,
"username" TEXT,
"pw_hash" TEXT,
"contact_person" TEXT,
"contact_email" TEXT,
"admin" INTEGER,
"oauth_id" TEXT
);