forked from I-TECH-UW/ci-hie-demo
-
Notifications
You must be signed in to change notification settings - Fork 9
68 lines (52 loc) · 1.85 KB
/
main.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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-test:
timeout-minutes: 20
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
lfs: true
- name: Checkout LFS objects
run: git lfs checkout
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Pull containers
run: docker-compose pull
- name: Cache containers
uses: satackey/[email protected]
continue-on-error: true
- name: Start containers
run: docker-compose up -d sigdep3 sigdep-db openhim-core mongo-db opencr-fhir opencr openhim-config es openhim-console
- name: Display docker logs for openhim config
run: docker-compose logs openhim-config
- name: Display docker logs for OpenCR
run: docker-compose logs opencr opencr-fhir
- name: Display container status
run: docker-compose ps
- name: Pause for a bit
run: sleep 120
shell: bash
- name: Display logs
if: always()
run: docker-compose logs sigdep3 opencr openhim-core
- name: Wait For SIGDEP3
run: docker-compose --profile=utility up --exit-code-from wait-for-openmrs wait-for-openmrs
- name: Run General Tests (https://www.postman.com/itechuw/workspace/ci-tap-demo/collection/1525496-efd9833a-2019-4248-813b-ed6f9d516537?action=share&creator=1525496)
env:
POSTMAN_COLLECTION: /.postman/1-general-tests.json
run: docker-compose --profile test up --exit-code-from newman newman
- name: Display logs
if: always()
run: docker-compose logs opencr openhim-core
- name: Stop containers
if: always()
run: docker-compose down -v