-
Notifications
You must be signed in to change notification settings - Fork 24
52 lines (45 loc) · 1.45 KB
/
build_and_test_using_docker.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: Build and test using Docker
on:
pull_request:
push:
schedule:
- cron: '0 16 * * 5' # Every Friday 4pm
workflow_dispatch:
jobs:
build_and_test:
name: Build and test using Docker
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
# NOTE: docker-compose breaks with Python >=3.13
- name: Set up Python 3.12
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: 3.12
- name: Install dependencies
run: |-
pip install \
--disable-pip-version-check \
--user \
--no-warn-script-location \
'docker<7' \
'PyYAML==5.3.1' \
'requests<2.32.0' \
'urllib3<2' \
docker-compose
echo "PATH=${HOME}/.local/bin:${PATH}" >> "${GITHUB_ENV}"
- name: Configure Docker environment
run: |-
docker network create --internal ssl-reverse-proxy
tee .env <<-EOF
JAWANNDENN_POSTGRES_NAME=jawanndenn111
JAWANNDENN_POSTGRES_USER=jawanndenn222
JAWANNDENN_POSTGRES_PASSWORD=jawanndenn333
JAWANNDENN_SECRET_KEY=jawanndenn444
EOF
- name: Build Docker image
run: |-
docker-compose build
- name: Run tests using Docker
run: |-
docker-compose run jawanndenn test -v2