3
3
build :
4
4
machine : true
5
5
working_directory : ~/apache
6
- environment :
7
- CIRCLE_ARTIFACTS : ~/logs/container-build
8
6
9
7
steps :
10
8
- checkout
11
9
12
10
- run :
13
- name : Build Docker image
11
+ name : Build Apache Docker image
14
12
command : |
15
- echo "Building Docker Image"
16
13
docker build -t htmlgraphic/apache:envoyer .
17
14
18
15
@@ -26,24 +23,23 @@ jobs:
26
23
pwd
27
24
make run
28
25
docker ps -a
26
+ sleep 10
29
27
30
28
31
- - run : |
32
- mkdir -p $CIRCLE_ARTIFACTS
33
- docker logs apache_web_1 > $CIRCLE_ARTIFACTS/log_output.txt
29
+ - run : mkdir -p ~/apache/logs/container-build
34
30
35
31
- run :
36
- name : DEV Build Tests
32
+ name : Container Logs
37
33
command : |
38
- docker exec apache_web_1 /bin/bash -c "/usr/bin/wget -q -O- http://127.0.0.1"
34
+ docker logs apache_web_1 > ~/apache/logs/container-build/log_output-DEV.txt
39
35
40
36
- run :
41
- name : DEV Build Tests 1
37
+ name : Global Environment Vars
42
38
command : |
43
39
docker exec apache_web_1 /bin/bash -c "export"
44
40
45
41
- run :
46
- name : DEV Build Tests 2
42
+ name : DEV Build Tests
47
43
command : |
48
44
docker exec apache_web_1 /bin/bash /opt/tests/build_tests.sh
49
45
@@ -54,28 +50,31 @@ jobs:
54
50
make stop && make rm
55
51
56
52
53
+ # LIVE Build
57
54
58
- - store_artifacts :
59
- path : ~/logs/container-build
60
- destination : raw-test-output
55
+ - run :
56
+ name : Start LIVE Container
57
+ command : |
58
+ docker-compose up -d
59
+ docker ps -a
60
+ sleep 10
61
61
62
- - store_test_results :
63
- path : ~/logs/container-build
62
+ - run :
63
+ name : LIVE Build Tests
64
+ command : |
65
+ docker exec apache_hg-web_1 /bin/bash /opt/tests/build_tests.sh
64
66
67
+ - run :
68
+ name : Container Logs
69
+ command : |
70
+ docker logs apache_hg-web_1 > ~/apache/logs/container-build/log_output-LIVE.txt
65
71
66
- # LIVE Build
67
72
68
- # - run:
69
- # name: Start LIVE Container
70
- # command: |
71
- # docker-compose up -d
72
- # docker ps -a
73
73
74
- # - run:
75
- # name: LIVE Build Tests
76
- # command: |
77
- # docker exec -it apache_web_1 /bin/bash /opt/tests/build_tests.sh
74
+ - store_artifacts :
75
+ path : ~/apache/logs/container-build
76
+ destination : raw-test-output
77
+
78
+ - store_test_results :
79
+ path : ~/apache/logs/container-build
78
80
79
- # - run: |
80
- # docker logs apache_web_1 > log_output
81
- # mv log_output $CIRCLE_ARTIFACTS/log_output-LIVE.txt
0 commit comments