Skip to content

Commit 5588cd6

Browse files
[CI] GitHub Action is used (#10)
Note: verification with alpine+py3.8.0 is excluded. This alpine image has the cutted "du" utility, that does not support "-b" option.
1 parent de92cfa commit 5588cd6

2 files changed

Lines changed: 61 additions & 30 deletions

File tree

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python
3+
4+
name: Python Verification
5+
6+
on:
7+
push:
8+
branches: [ "master" ]
9+
pull_request:
10+
branches: [ "master" ]
11+
12+
jobs:
13+
build:
14+
15+
runs-on: ubuntu-latest
16+
strategy:
17+
fail-fast: false
18+
matrix:
19+
include:
20+
- platform: "alpine"
21+
python: "3.7"
22+
- platform: "alpine"
23+
python: "3.8"
24+
- platform: "alpine"
25+
python: "3.9"
26+
- platform: "alpine"
27+
python: "3.10"
28+
- platform: "alpine"
29+
python: "3.11"
30+
- platform: "alpine"
31+
python: "3.12"
32+
- platform: "alpine"
33+
python: "3.13"
34+
- platform: "alpine"
35+
python: "3.14"
36+
37+
steps:
38+
- name: Prepare variables
39+
run: |
40+
RUN_CFG__LOGS_DIR="logs-${{ matrix.platform }}-py${{ matrix.python }}"
41+
echo "RUN_CFG__LOGS_DIR=$RUN_CFG__LOGS_DIR" >> $GITHUB_ENV
42+
RUN_CFG__DOCKER_IMAGE_NAME="tests-${{ matrix.platform }}-py${{ matrix.python }}"
43+
echo "RUN_CFG__DOCKER_IMAGE_NAME=$RUN_CFG__DOCKER_IMAGE_NAME" >> $GITHUB_ENV
44+
echo "---------- [$GITHUB_ENV]"
45+
cat $GITHUB_ENV
46+
- name: Checkout
47+
uses: actions/checkout@v4
48+
- name: Prepare logs folder on the host
49+
run: mkdir -p "${{ env.RUN_CFG__LOGS_DIR }}"
50+
- name: Adjust logs folder permission
51+
run: chmod -R 777 "${{ env.RUN_CFG__LOGS_DIR }}"
52+
- name: Build local image ${{ matrix.alpine }}
53+
run: docker build --build-arg PYTHON_VERSION="${{ matrix.python }}" -t "${{ env.RUN_CFG__DOCKER_IMAGE_NAME }}" -f Dockerfile--${{ matrix.platform }}.tmpl .
54+
- name: Run
55+
run: docker run -t -v ${{ github.workspace }}/${{ env.RUN_CFG__LOGS_DIR }}:/home/test/testgres/logs "${{ env.RUN_CFG__DOCKER_IMAGE_NAME }}"
56+
- name: Upload Logs
57+
uses: actions/upload-artifact@v4
58+
if: always() # IT IS IMPORTANT!
59+
with:
60+
name: container-logs--${{ matrix.platform }}-py${{ matrix.python }}
61+
path: "${{ env.RUN_CFG__LOGS_DIR }}/"

.travis.yml

Lines changed: 0 additions & 30 deletions
This file was deleted.

0 commit comments

Comments
 (0)