From 885ec72f257da1481f0fac092cae3a49ea602c8f Mon Sep 17 00:00:00 2001
From: parsa aghaei
Date: Mon, 27 Jul 2026 16:52:19 +0330
Subject: [PATCH] ci(deploy): configure CI/CD for develop (stage.canina.ir) and
main (canina.ir) domains
---
.gitea/workflows/deploy.yml | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml
index 21e51e48..337079b9 100644
--- a/.gitea/workflows/deploy.yml
+++ b/.gitea/workflows/deploy.yml
@@ -1,7 +1,10 @@
name: Deploy Canina
+
on:
push:
- branches: [main]
+ branches:
+ - main
+ - develop
jobs:
deploy:
@@ -16,6 +19,10 @@ jobs:
echo "$SSH_KEY" > ~/.ssh/id_ed25519
chmod 600 ~/.ssh/id_ed25519
ssh-keyscan -p 2234 -H 172.17.0.1 >> ~/.ssh/known_hosts
+
- name: Deploy
shell: sh
- run: ssh -p 2234 devops@172.17.0.1 'bash /opt/services/scripts/depcanina.sh main'
+ run: |
+ BRANCH="${GITHUB_REF_NAME}"
+ echo "Deploying branch: ${BRANCH}"
+ ssh -o StrictHostKeyChecking=no -p 2234 devops@172.17.0.1 "bash /opt/services/scripts/depcanina.sh ${BRANCH}"