add new ci

This commit is contained in:
Smile Rex
2025-07-23 15:17:10 +03:00
parent 8fe324d878
commit 0919496792
3 changed files with 20 additions and 26 deletions

19
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,19 @@
name: Deploy to Docker Swarm (Worker Node)
on:
push:
branches: [main]
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Build and push Docker image
run: |
docker build -t ghcr.io/serverussnap/dickbot:latest .
echo "${{ secrets.GHCR_TOKEN }}" | docker login ghcr.io -u serverussnap --password-stdin
docker push ghcr.io/serverussnap/dickbot:latest

View File

@@ -1,22 +0,0 @@
name: Docker Image CI
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build the Docker image
run: docker build -t smilerex/dickbot:latest .
- name: Login docker
run: docker login -u ${{secrets.DOCKER_LOGIN}} -p ${{secrets.DOCKER_TOKEN}}
- name: Deploy docker registry
run: docker push smilerex/dickbot:latest

View File

@@ -10,10 +10,7 @@ import (
tele "gopkg.in/telebot.v4"
)
// //////////////////////
var isTest bool = true
////////////////////////
var isTest bool = false
func config() models.Config {
return models.Config{