This commit is contained in:
14
.gitea/workflows/deploy.sh
Normal file
14
.gitea/workflows/deploy.sh
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
#!/usr/bin/env sh
|
||||||
|
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Config
|
||||||
|
PORTAINER_URL="http://192.168.1.17:9000"
|
||||||
|
API_KEY="${PORTAINER_API_KEY}" # store this securely!
|
||||||
|
STACK_ID=27 # local_stuff stack
|
||||||
|
|
||||||
|
# Redeploy Stack
|
||||||
|
curl -s -X POST "$PORTAINER_URL/api/stacks/$STACK_ID/redeploy" \
|
||||||
|
-H "X-API-Key: $API_KEY" \
|
||||||
|
-H "Content-Type: application/json" \
|
||||||
|
-d '{}'
|
||||||
@@ -30,4 +30,11 @@ jobs:
|
|||||||
context: .
|
context: .
|
||||||
file: ./Dockerfile
|
file: ./Dockerfile
|
||||||
push: true
|
push: true
|
||||||
tags: gitea.abzk.fr/mrzaiko/jarvis:latest
|
tags: gitea.abzk.fr/mrzaiko/jarvis:latest
|
||||||
|
|
||||||
|
- name: Deploy to Portainer
|
||||||
|
run: |
|
||||||
|
curl -s -X POST "http://192.168.1.17:9000/api/stacks/27/redeploy" \
|
||||||
|
-H "X-API-Key: ${{ secrets.PORTAINER_API_KEY }}" \
|
||||||
|
-H "Content-Type: application/json" \
|
||||||
|
-d '{}'
|
||||||
|
|||||||
2
main.py
2
main.py
@@ -113,6 +113,8 @@ async def handle_menu(update: Update, context: ContextTypes.DEFAULT_TYPE) -> Non
|
|||||||
|
|
||||||
# --- Main Function ---
|
# --- Main Function ---
|
||||||
def main():
|
def main():
|
||||||
|
print("Starting Jarvis...")
|
||||||
|
|
||||||
# Initiate api
|
# Initiate api
|
||||||
kuma_api = kuma.KumaAPI("http://192.168.1.2:36667", "k!PTfyvoIJho9o*gX6F1")
|
kuma_api = kuma.KumaAPI("http://192.168.1.2:36667", "k!PTfyvoIJho9o*gX6F1")
|
||||||
torrent_api = torrent.TorrentApi("http://192.168.1.17:8112", "tMHNjrJr7nhjyhJrYsahi4anq2h6LJ")
|
torrent_api = torrent.TorrentApi("http://192.168.1.17:8112", "tMHNjrJr7nhjyhJrYsahi4anq2h6LJ")
|
||||||
|
|||||||
Reference in New Issue
Block a user