This repository has been archived on 2026-03-27. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
bot/.github/deploy.yml
Stanisław Dzioba 0fe99e10cf change branch name
2022-12-16 21:49:48 +01:00

21 lines
594 B
YAML

name: Deploy
on:
push:
branches: ['master']
pull_request:
branches: ['master']
jobs:
build:
runs-on: self-hosted
steps:
- uses: actions/checkout@v3
- name: Build image
run: docker build -t ${{ github.repository }} .
- name: Deploy image
run: |
docker stop ${{ github.event.repository.name }} || true
docker rm ${{ github.event.repository.name }} || true
docker run -d -e "DISCORD_TOKEN=${{ secrets.TOKEN }}" --restart always -p 2020:2020 --name ${{ github.event.repository.name }} ${{ github.repository }}