mirror of
https://github.com/kurbezz/discord-bot.git
synced 2025-12-06 15:15:37 +01:00
Update
This commit is contained in:
12
scripts/env.sh
Normal file
12
scripts/env.sh
Normal file
@@ -0,0 +1,12 @@
|
||||
#! /usr/bin/env sh
|
||||
|
||||
response=`curl -X 'GET' "https://$VAULT_HOST/v1/$VAULT_SECRET_PATH" -s \
|
||||
-H 'accept: application/json' \
|
||||
-H "X-Vault-Token: $VAULT_TOKEN"`
|
||||
|
||||
data=`echo $response | jq -r '.data.data'`
|
||||
|
||||
for key in $(echo "$data" | jq -r 'keys[]'); do
|
||||
value=$(echo "$data" | jq -r ".\"$key\"") # Corrected syntax
|
||||
echo "$key"="$value"
|
||||
done
|
||||
5
scripts/start_app.sh
Normal file
5
scripts/start_app.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#! /usr/bin/env sh
|
||||
|
||||
export $(/env.sh)
|
||||
|
||||
/opt/venv/bin/python main.py $1
|
||||
5
scripts/start_scheduler.sh
Normal file
5
scripts/start_scheduler.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#! /usr/bin/env sh
|
||||
|
||||
export $(/env.sh)
|
||||
|
||||
/opt/venv/bin/taskiq scheduler core.broker:scheduler modules.tasks
|
||||
5
scripts/start_worker.sh
Normal file
5
scripts/start_worker.sh
Normal file
@@ -0,0 +1,5 @@
|
||||
#! /usr/bin/env sh
|
||||
|
||||
export $(/env.sh)
|
||||
|
||||
/opt/venv/bin/taskiq worker core.broker:broker modules.tasks
|
||||
Reference in New Issue
Block a user