-
Notifications
You must be signed in to change notification settings - Fork 38
/
.travis.yml
102 lines (66 loc) · 2.41 KB
/
.travis.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
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
dist: trusty
sudo: required
language: bash
addons:
apt:
packages:
- mysql-server-5.6
- mysql-client-core-5.6
- mysql-client-5.6
services:
- mysql
before_install:
# Install 'shellcheck' and 'tmpreaper'
- sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu/ trusty-backports restricted main universe"
- sudo apt-get update -qq
- sudo apt-get install -qq shellcheck tmpreaper
before_script:
# -------------------- MySQL --------------------
# Installs mysqldump-secure and MySQL as with as master and a slave server
- ./test/00-install.sh
- sleep 10
- sudo mysql --ssl-ca=/opt/mysqldump-secure/tests/etc/mysql.ca.pem --user=root --host=127.0.0.1 --port=13306 -e "status;"
- sudo mysql --ssl-ca=/opt/mysqldump-secure/tests/etc/mysql.ca.pem --user=root --host=127.0.0.1 --port=13307 -e "status;"
# 6. Show config
# - sudo cat /etc/mysqldump-secure.conf
script:
# --------------------------------------------------------------------------------
#
# SOURCE CODE LINTING
#
# --------------------------------------------------------------------------------
# Shellcheck
- shellcheck --shell=sh bin/mysqldump-secure
- shellcheck --shell=sh bin/create-keypair.sh
- shellcheck --shell=sh bin/decrypt.sh
- shellcheck --shell=sh bin/encrypt.sh
- shellcheck --shell=sh --exclude=SC2034,SC2148 etc/mysqldump-secure.conf
# --------------------------------------------------------------------------------
#
# Checks
#
# --------------------------------------------------------------------------------
- ./test/01-check_normal-operation.sh
- ./test/02-check_output_dirs.sh
- ./test/03-check_connection_settings.sh
- ./test/04-check_mysqldump_settings.sh
- ./test/05-check_consistency_settings.sh
- ./test/06-check_logging.sh
- ./test/07-check_compression.sh
- ./test/08-check_encryption.sh
- ./test/09-check_deletion.sh
- ./test/10-check_nagios_log.sh
- ./test/11-check_info_file.sh
- ./test/12-check_misc_settings.sh
# TODO:
# * Duplicate files testing!!!
# * Connection checking (host not found, access denied, etc)
# * master/slave tests
# * nagios check
# --------------------------------------------------------------------------------
#
# Show info
#
# --------------------------------------------------------------------------------
# Contents of dump folder
#- sudo ls -la /var/mysqldump-secure