Skip to content

Commit

Permalink
Merge pull request #237 from intelops/migrationbugfix
Browse files Browse the repository at this point in the history
added sql statements for all tables
  • Loading branch information
vijeyash1 authored Sep 21, 2023
2 parents d4a4d31 + 8ae014a commit 2b3e3ef
Show file tree
Hide file tree
Showing 42 changed files with 253 additions and 292 deletions.
20 changes: 0 additions & 20 deletions sql/20230912051648_clickhouse.down.sql

This file was deleted.

272 changes: 0 additions & 272 deletions sql/20230912051648_clickhouse.up.sql

This file was deleted.

1 change: 1 addition & 0 deletions sql/20230915101223_events.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS events;
15 changes: 15 additions & 0 deletions sql/20230915101223_events.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
CREATE TABLE IF NOT EXISTS events (
ClusterName String,
Id String,
EventTime DateTime('UTC'),
OpType String,
Name String,
Namespace String,
Kind String,
Message String,
Reason String,
Host String,
Event String,
FirstTime String,
LastTime String
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101317_rakkess.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS rakkess;
9 changes: 9 additions & 0 deletions sql/20230915101317_rakkess.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
CREATE TABLE IF NOT EXISTS rakkess (
ClusterName String,
Name String,
Create String,
Delete String,
List String,
Update String,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101358_DeprecatedAPIs.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS DeprecatedAPIs;
9 changes: 9 additions & 0 deletions sql/20230915101358_DeprecatedAPIs.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
CREATE TABLE IF NOT EXISTS DeprecatedAPIs (
ClusterName String,
ObjectName String,
Description String,
Kind String,
Deprecated UInt8,
Scope String,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101437_DeletedAPIs.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS DeletedAPIs;
11 changes: 11 additions & 0 deletions sql/20230915101437_DeletedAPIs.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
CREATE TABLE IF NOT EXISTS DeletedAPIs (
ClusterName String,
ObjectName String,
Group String,
Kind String,
Version String,
Name String,
Deleted UInt8,
Scope String,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101512_jfrogcontainerpush.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS jfrogcontainerpush;
12 changes: 12 additions & 0 deletions sql/20230915101512_jfrogcontainerpush.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
CREATE TABLE IF NOT EXISTS jfrogcontainerpush (
Domain String,
EventType String,
RegistryURL String,
RepositoryName String,
SHAID String,
Size Int32,
ImageName String,
Tag String,
Event String,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101549_getall_resources.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS getall_resources;
8 changes: 8 additions & 0 deletions sql/20230915101549_getall_resources.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
CREATE TABLE IF NOT EXISTS getall_resources (
ClusterName String,
Namespace String,
Kind String,
Resource String,
Age String,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101643_outdated_images.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS outdated_images;
10 changes: 10 additions & 0 deletions sql/20230915101643_outdated_images.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
CREATE TABLE IF NOT EXISTS outdated_images (
ClusterName String,
Namespace String,
Pod String,
CurrentImage String,
CurrentTag String,
LatestVersion String,
VersionsBehind Int64,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
1 change: 1 addition & 0 deletions sql/20230915101736_kubescore.down.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DROP TABLE IF EXISTS kubescore;
7 changes: 7 additions & 0 deletions sql/20230915101736_kubescore.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
CREATE TABLE IF NOT EXISTS kubescore (
id UUID,
namespace String,
cluster_name String,
recommendations String,
EventTime DateTime('UTC')
) engine=File(TabSeparated);
Loading

0 comments on commit 2b3e3ef

Please sign in to comment.