Merge pull request #9 from oroneta/MergeDDBB #11
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/Podman CI | |
on: | |
push: | |
branches: [ "master" ] | |
pull_request: | |
branches: [ "master" ] | |
jobs: | |
run: | |
runs-on: ubuntu-latest | |
services: | |
docker: | |
image: docker:dind | |
options: --privileged=true | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Install build dependencies | |
run: | | |
sudo apt update | |
sudo apt install -y python3 | |
- name: Check docker and podman | |
run: | | |
docker --version | |
podman --version | |
- name: Set up Docker | |
run: | | |
cd ./docker | |
docker compose up -d --build | |
if [ $( docker ps -q | wc -l ) -lt 3 ] | |
then | |
echo "Test failed, docker not alive" | |
exit 1 | |
fi | |
docker ps | |
docker container ls | |
# - name: Test docker container | |
# run: | | |
# cd ./test | |
# python3 -m pip install -r requeriments.txt | |
# python3 pytester.py 2 | |
# python3 pytester.py 1 |