mirror of
https://github.com/Paillat-dev/Botator.git
synced 2026-01-02 09:16:19 +00:00
[GH/WORKFLOW] Added docker workflow
This commit is contained in:
21
.github/workflows/buildDockerImage.yml
vendored
Normal file
21
.github/workflows/buildDockerImage.yml
vendored
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
# Building Docker image and pushing it to Docker Hub
|
||||||
|
|
||||||
|
name: Build Docker Image
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Build Docker image
|
||||||
|
run: |
|
||||||
|
docker build -t ${{ secrets.DOCKER_USERNAME }}/botator:${{ github.sha }} .
|
||||||
|
- name: Push Docker image to Docker Hub
|
||||||
|
run: |
|
||||||
|
echo ${{ secrets.DOCKER_PASSWORD }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin
|
||||||
|
docker push ${{ secrets.DOCKER_USERNAME }}/botator:${{ github.sha }}
|
||||||
Reference in New Issue
Block a user