-
Notifications
You must be signed in to change notification settings - Fork 48
/
docker-compose.test.yaml
222 lines (185 loc) · 5.89 KB
/
docker-compose.test.yaml
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
services:
test-e2e:
build:
context: .
dockerfile: docker/Dockerfile
env_file: env.test
command: python -m unittest discover test.e2e
volumes:
# We don't copy the test code into the image so that we don't pollute production image
# with test data.
- ./test/:/opt/test/
- ./docker/karton.ini:/etc/karton/karton.ini
- data-test:/data/
test:
build:
context: .
dockerfile: docker/Dockerfile
command: bash -c "python -m unittest discover test.modules && python -m unittest discover test.reporting && python -m unittest discover test.unit"
environment:
TEST_REDIS_HOST: test-redis
TEST_REDIS_PORT: 6379
BRUTER_FILE_LIST: full
RUNNING_TESTS: "true"
# Use only one provider to speed up the tests
SUBDOMAIN_ENUMERATION_GAU_ADDITIONAL_OPTIONS: "--providers wayback"
SQL_INJECTION_STOP_ON_FIRST_MATCH: False
POSTMAN_MAIL_FROM: [email protected]
POSTMAN_MAIL_TO: [email protected]
REQUESTS_PER_SECOND: 0
CUSTOM_PORT_SCANNER_PORTS: 21,80,6379
NUCLEI_CHECK_TEMPLATE_LIST: False
env_file: env.test
volumes:
# We don't copy the test code into the image so that we don't pollute production image
# with test data.
- ./test/:/opt/test/
- ./docker/karton.ini:/etc/karton/karton.ini
test-redis:
image: redis:7.0.5
postgres-test:
image: postgres
restart: always
shm_size: 256mb
environment:
POSTGRES_DB: artemis
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
sql-injection-test-postgres:
image: postgres
restart: always
shm_size: 256mb
environment:
POSTGRES_DB: artemis
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
sql-injection-test-mysql:
image: mysql:5.6
environment:
MYSQL_ROOT_PASSWORD: root
test-service-with-bruteable-files:
image: php:7.4-apache
volumes:
- ./test/data/bruteable_files/:/var/www/html/
test-robots-service:
image: nginx:latest
volumes:
- ./test/data/robots/default.conf:/etc/nginx/conf.d/default.conf
- ./test/data/robots/:/usr/share/nginx/html/
test-php-xss-but-not-on-homepage:
image: php:8.0-apache
volumes:
- ./test/data/php_xss_but_not_on_homepage/:/var/www/html/
test-ftp-server-with-easy-password:
image: stilliard/pure-ftpd:latest
environment:
- FTP_USER_NAME=admin
- FTP_USER_PASS=12345
- FTP_USER_HOME=/dev/shm
test-old-joomla:
image: joomla:4.0.5-php8.0-apache # this is an old image on purpose
environment:
JOOMLA_DB_HOST: test-old-joomla-mysql
JOOMLA_DB_PASSWORD: example
test-old-joomla-mysql:
image: mysql:5.6
environment:
MYSQL_ROOT_PASSWORD: example
test-smtp-server:
hostname: test-smtp-server.artemis
image: bytemark/smtp
test-nginx:
image: nginx:latest
test-service-with-exposed-git:
image: nginx:latest
volumes:
- ./test/data/git/git/:/usr/share/nginx/html/.git/
test-old-wordpress:
image: wordpress:5.9.3-apache
environment:
WORDPRESS_DB_HOST: test-old-wordpress-mysql
WORDPRESS_DB_USER: root
WORDPRESS_DB_PASSWORD: example
WORDPRESS_DB_NAME: example
test-old-wordpress-mysql:
image: mysql:5.6
environment:
MYSQL_ROOT_PASSWORD: example
test-service-with-directory-index:
image: nginx:latest
volumes:
- ./test/data/directory_index/default.conf:/etc/nginx/conf.d/default.conf
- ./test/data/directory_index/:/usr/share/nginx/html/
test-wordpress-easy-password:
image: wordpress:6.3.2-apache
environment:
WORDPRESS_DB_HOST: test-wordpress-easy-password-mysql
WORDPRESS_DB_USER: root
WORDPRESS_DB_PASSWORD: example
WORDPRESS_DB_NAME: example
test-wordpress-easy-password-mysql:
image: mysql:5.6
environment:
MYSQL_ROOT_PASSWORD: example
test-mysql-with-easy-password:
image: mysql:5.6
environment:
MYSQL_ROOT_PASSWORD: root
test-ssh-with-easy-password:
image: lscr.io/linuxserver/openssh-server:latest
environment:
PASSWORD_ACCESS: true
USER_PASSWORD: password
USER_NAME: user
ports:
- "2222:2222"
test-postgresql-with-easy-password:
image: postgres
environment:
POSTGRES_USER: example
POSTGRES_PASSWORD: example
test-phpmyadmin-easy-password-subdirectory-nginx:
image: nginx
volumes:
- ./test/data/phpmyadmin_subdirectory_proxy/default.conf:/etc/nginx/conf.d/default.conf
test-phpmyadmin-easy-password-subdirectory:
image: phpmyadmin
environment:
- PMA_ABSOLUTE_URI=http://test-phpmyadmin-easy-password-subdirectory-nginx/phpmyadmin/
- PMA_HOST=test-phpmyadmin-easy-password-mysql
test-phpmyadmin-easy-password:
image: phpmyadmin
environment:
- PMA_HOST=test-phpmyadmin-easy-password-mysql
test-phpmyadmin-easy-password-mysql:
image: mariadb:10.3
environment:
MYSQL_ROOT_PASSWORD: root
test-service-with-bruteable-files-sql-dumps:
image: php:7.4-apache
volumes:
- ./test/reporting/data/bruteable_files/sql_dumps/:/var/www/html/
test-service-with-bruteable-files-htpasswd:
image: php:7.4-apache
volumes:
- ./test/reporting/data/bruteable_files/htpasswd/:/var/www/html/
test_apache-with-xss:
build:
dockerfile: test/images/php-xss/Dockerfile
command: systemctl start apache2.service
volumes:
- ./test/data/dalfox/:/var/www/html/
test-apache-with-sql-injection-postgres:
build:
dockerfile: test/images/php-postgres/Dockerfile
command: systemctl start apache2.service
volumes:
- ./test/data/sql_injection_postgres/:/var/www/html/
test-apache-with-sql-injection-mysql:
build:
dockerfile: test/images/php-mysql/Dockerfile
command: systemctl start apache2.service
volumes:
- ./test/data/sql_injection_mysql/:/var/www/html/
volumes:
data-test: