Some checks failed
Fetch and Run Hello World Docker Image / fetch-hello-world (push) Failing after 1s
24 lines
582 B
YAML
24 lines
582 B
YAML
name: "Fetch and Run Hello World Docker Image"
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main # Change to 'master' if that is your default branch
|
|
|
|
jobs:
|
|
fetch-hello-world:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: "Set up Docker"
|
|
run: |
|
|
docker --version || sudo apt-get update && sudo apt-get install -y docker.io
|
|
|
|
- name: "Pull and Run Hello World"
|
|
run: |
|
|
echo "Pulling and running Hello World Docker image..."
|
|
docker pull hello-world
|
|
|
|
# Run the Hello World image
|
|
docker run --rm hello-world
|
|
|