49 lines (40 loc) · 1.06 KB
/
deployment.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Deployment
on:
push:
branches: [ default ]
jobs:
build_and_deploy:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Install Base Dependencies
run: |
sudo apt-get update
sudo apt-get install python3-venv
pip3 install poetry git+https://github.com/mmh352/ou-container-builder.git
- name: Generate the Dockerfile
run: |
ou-container-builder --no-build
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Docker meta
id: meta
uses: docker/metadata-action@v3
with:
images: mmh352/tm129-robotics-21j
flavor: |
latest=true
tags: |
type=sha
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: mmh352
password: ${{ secrets.DOCKERACCESSTOKEN }}
- name: Build and push the Docker image
uses: docker/build-push-action@v2
with:
pull: false
push: true
tags: ${{ steps.meta.outputs.tags }}
context: .