feat: add surrealdb
This commit is contained in:
parent
3fc7b0d2dc
commit
30f736b399
1902
Cargo.lock
generated
1902
Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@ -43,6 +43,7 @@ serenity = { version = "0.12", default-features = false, features = [
|
|||||||
tokio = { version = "1.35", features = ["macros", "rt-multi-thread"] }
|
tokio = { version = "1.35", features = ["macros", "rt-multi-thread"] }
|
||||||
rand = "0.8.5"
|
rand = "0.8.5"
|
||||||
walkdir = "2.4.0"
|
walkdir = "2.4.0"
|
||||||
|
surrealdb = "1.1.1"
|
||||||
|
|
||||||
|
|
||||||
[[bin]]
|
[[bin]]
|
||||||
|
40
devfile.yaml
40
devfile.yaml
@ -10,6 +10,10 @@ projects:
|
|||||||
remotes:
|
remotes:
|
||||||
origin: git@git.weebo.fr:sandbox/BotDiscord.git
|
origin: git@git.weebo.fr:sandbox/BotDiscord.git
|
||||||
|
|
||||||
|
variables:
|
||||||
|
DB_PASSWORD: "bot_password_azertdsq"
|
||||||
|
DB_USER: "bot_root"
|
||||||
|
|
||||||
components:
|
components:
|
||||||
- name: tools
|
- name: tools
|
||||||
container:
|
container:
|
||||||
@ -28,22 +32,34 @@ components:
|
|||||||
value: "dev-che"
|
value: "dev-che"
|
||||||
- name: "PORT"
|
- name: "PORT"
|
||||||
value: "5437"
|
value: "5437"
|
||||||
- name: postgres
|
- name: DB_USER
|
||||||
|
value: "{{DB_USER}}"
|
||||||
|
- name: DB_PASSWORD
|
||||||
|
value: "{{DB_PASSWORD}}"
|
||||||
|
- name: surrealdb
|
||||||
container:
|
container:
|
||||||
image: postgres:15
|
image: surrealdb/surrealdb:latest
|
||||||
memoryLimit: 2Gi
|
memoryLimit: 2Gi
|
||||||
|
args:
|
||||||
|
- "start"
|
||||||
endpoints:
|
endpoints:
|
||||||
- name: postgres
|
- name: surrealdb
|
||||||
targetPort: 5432
|
targetPort: 8000
|
||||||
env:
|
env:
|
||||||
- name: POSTGRES_USER
|
- name: SURREAL_AUTH
|
||||||
value: "postgres"
|
value: "true"
|
||||||
- name: POSTGRES_PASSWORD
|
- name: SURREAL_USER
|
||||||
value: "postgres"
|
value: "{{DB_USER}}"
|
||||||
- name: POSTGRES_DB
|
- name: SURREAL_PASS
|
||||||
value: "postgres"
|
value: "{{DB_PASSWORD}}"
|
||||||
- name: PGDATA
|
- name: SURREAL_PATH
|
||||||
value: /tmp/pgdata
|
value: "file:/appdata/bot.db"
|
||||||
|
volumeMounts:
|
||||||
|
- name: db-volume
|
||||||
|
path: /appdata
|
||||||
|
- name: db-volume
|
||||||
|
volume:
|
||||||
|
size: 2Gi
|
||||||
commands:
|
commands:
|
||||||
- id: build
|
- id: build
|
||||||
exec:
|
exec:
|
||||||
|
Loading…
Reference in New Issue
Block a user