This repository has been archived by the owner on Feb 10, 2025. It is now read-only.
Update docker-image.yml #15
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker Image CI | |
on: | |
workflow_dispatch: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Print Docker version | |
run: docker version | |
- name: Build | |
run: docker build -t hie:${{ github.sha }} . | |
run_and_test: | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- name: Run | |
run: | | |
docker run -d --name hie -p 5888:3000 hie:${{ github.sha }} | |
sleep 10 | |
- name: Test | |
run: | | |
curl --silent --fail http://localhost:5888 || exit 1 |