-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
25 changed files
with
4,291 additions
and
2,877 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,19 @@ | ||
MYSQL_DATABASE_URL="mysql://root:my-secret-pw@localhost/ayane_dev" | ||
POSTGRES_DATABASE_URL="postgres://postgres:postgres@localhost/ayane_dev" | ||
REDIS_URL="redis://localhost:6379/0" | ||
NODE_ENV=development | ||
REDIS_URL="redis://127.0.0.1:6379/0" | ||
|
||
UPSTASH_REDIS_REST_URL="" | ||
UPSTASH_REDIS_REST_TOKEN="" | ||
AYANE_PLANETSCALE_LABEL="planetscale" | ||
AYANE_PLANETSCALE_TYPE="mysql" | ||
AYANE_PLANETSCALE_ARG_1="mysql://root:my-secret-pw@localhost/ayane_dev" | ||
|
||
AYANE_SUPABASE_LABEL="supabase" | ||
AYANE_SUPABASE_TYPE="postgres" | ||
AYANE_SUPABASE_ARG_1="postgres://postgres:postgres@localhost/ayane_dev" | ||
|
||
AYANE_REDISLAB_LABEL="redislab" | ||
AYANE_REDISLAB_TYPE="redis_native" | ||
AYANE_REDISLAB_ARG_1="redis://localhost:6379/0" | ||
|
||
AYANE_UPSTASH_REDIS_LABEL="upstash_redis" | ||
AYANE_UPSTASH_REDIS_TYPE="upstash_redis" | ||
AYANE_UPSTASH_REDIS_ARG_1="TODO:UPSTASH_REDIS_REST_URL" | ||
AYANE_UPSTASH_REDIS_ARG_2="TODO:UPSTASH_REDIS_REST_TOKEN" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -146,3 +146,4 @@ dist | |
.esbuild | ||
.env.development | ||
output | ||
artifact |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
CREATE TABLE `ayane_kernel` ( | ||
`id` INTEGER NOT NULL AUTO_INCREMENT, | ||
`name` VARCHAR(191) NOT NULL, | ||
`value` TEXT NOT NULL, | ||
`created_at` DATETIME(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3), | ||
`updated_at` DATETIME(3) NOT NULL DEFAULT CURRENT_TIMESTAMP(3) ON UPDATE CURRENT_TIMESTAMP(3), | ||
|
||
UNIQUE INDEX `ayane_kernel_name_key`(`name`), | ||
PRIMARY KEY (`id`) | ||
) DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
-- https://x-team.com/blog/automatic-timestamps-with-postgresql/ | ||
CREATE OR REPLACE FUNCTION trigger_set_timestamp() | ||
RETURNS TRIGGER AS $$ | ||
BEGIN | ||
NEW.updated_at = NOW(); | ||
RETURN NEW; | ||
END; | ||
$$ LANGUAGE plpgsql; | ||
|
||
CREATE TABLE "ayane_kernel" ( | ||
"id" SERIAL NOT NULL PRIMARY KEY, | ||
"name" VARCHAR NOT NULL, | ||
"value" TEXT NOT NULL, | ||
"created_at" TIMESTAMPTZ NOT NULL DEFAULT NOW(), | ||
"updated_at" TIMESTAMPTZ NOT NULL DEFAULT NOW() | ||
); | ||
|
||
CREATE TRIGGER set_timestamp | ||
BEFORE UPDATE ON ayane_kernel | ||
FOR EACH ROW | ||
EXECUTE PROCEDURE trigger_set_timestamp(); | ||
|
||
CREATE UNIQUE INDEX "ayane_kernel_name_key" ON "ayane_kernel"("name"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.