27 lines
652 B
YAML
27 lines
652 B
YAML
name: Gitea actions demo.
|
|
|
|
on: [push]
|
|
|
|
jobs:
|
|
build:
|
|
image: ubuntu-latest
|
|
steps:
|
|
- name: Check out repository code
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Build Docker Image
|
|
run: |
|
|
docker build -t hello-world-image .
|
|
run-app:
|
|
image: ubuntu-latest
|
|
steps:
|
|
- name: Run Docker Container
|
|
run: |
|
|
docker run --name hello-world-container --rm hello-world-image
|
|
|
|
cleanup:
|
|
image: ubuntu-latest
|
|
steps:
|
|
- name: Remove Docker Image
|
|
run: |
|
|
docker rmi -f hello-world-image |