summaryrefslogtreecommitdiffstats
path: root/docker/files
diff options
context:
space:
mode:
authorDavid Lawrence <dkl@mozilla.com>2015-11-06 23:21:30 +0100
committerDavid Lawrence <dkl@mozilla.com>2015-11-06 23:21:30 +0100
commitaf46939af5dbe914e07c9b1ec0af2560b38ffbc6 (patch)
treee3614dddfd2dff0a027c59345f70343f76619eb5 /docker/files
parent60bde01b7ffc861a7bfba352af015b2b154e6f1e (diff)
downloadbugzilla-af46939af5dbe914e07c9b1ec0af2560b38ffbc6.tar.gz
bugzilla-af46939af5dbe914e07c9b1ec0af2560b38ffbc6.tar.xz
Bug 1222497 - Refactor the BMO docker image with new file and script structure while minimizing final image size
Diffstat (limited to 'docker/files')
-rw-r--r--docker/files/bugzilla.conf19
-rw-r--r--docker/files/checksetup_answers.txt27
-rw-r--r--docker/files/my.cnf42
-rw-r--r--docker/files/rpm_list34
-rw-r--r--docker/files/sudoers9
-rw-r--r--docker/files/supervisord.conf25
6 files changed, 156 insertions, 0 deletions
diff --git a/docker/files/bugzilla.conf b/docker/files/bugzilla.conf
new file mode 100644
index 000000000..857f79d17
--- /dev/null
+++ b/docker/files/bugzilla.conf
@@ -0,0 +1,19 @@
+User bugzilla
+Group bugzilla
+ServerName localhost:80
+
+#PerlSwitches -wT
+#PerlConfigRequire /home/bugzilla/devel/htdocs/bmo/mod_perl.pl
+
+<VirtualHost *:80>
+ #AddHandler perl-script .cgi
+ AddHandler cgi-script .cgi
+ ServerName localhost
+ DocumentRoot "/home/bugzilla/devel/htdocs"
+ <Directory "/home/bugzilla/devel/htdocs">
+ DirectoryIndex index.cgi
+ Options Indexes FollowSymLinks ExecCGI
+ AllowOverride All
+ Require all granted
+ </Directory>
+</VirtualHost>
diff --git a/docker/files/checksetup_answers.txt b/docker/files/checksetup_answers.txt
new file mode 100644
index 000000000..0ab75aac9
--- /dev/null
+++ b/docker/files/checksetup_answers.txt
@@ -0,0 +1,27 @@
+$answer{'ADMIN_EMAIL'} = 'admin@mozilla.test';
+$answer{'ADMIN_OK'} = 'Y';
+$answer{'ADMIN_PASSWORD'} = 'password';
+$answer{'ADMIN_REALNAME'} = 'QA Admin';
+$answer{'NO_PAUSE'} = 1;
+$answer{'bugzilla_version'} = '4.2';
+$answer{'create_htaccess'} = '';
+$answer{'cvsbin'} = '/usr/bin/cvs';
+$answer{'db_check'} = 1;
+$answer{'db_driver'} = 'mysql';
+$answer{'db_host'} = 'localhost';
+$answer{'db_mysql_ssl_ca_file'} = '';
+$answer{'db_mysql_ssl_ca_path'} = '';
+$answer{'db_mysql_ssl_client_cert'} = '';
+$answer{'db_mysql_ssl_client_key'} = '';
+$answer{'db_name'} = 'bugs',
+$answer{'db_pass'} = 'bugs';
+$answer{'db_port'} = 0;
+$answer{'db_sock'} = '';
+$answer{'db_user'} = 'bugs';
+$answer{'diffpath'} = '/usr/bin';
+$answer{'index_html'} = 0;
+$answer{'interdiffbin'} = '/usr/bin/interdiff';
+$answer{'memcached_servers'} = "localhost:11211";
+$answer{'urlbase'} = 'http://localhost/bmo/';
+$answer{'use_suexec'} = '';
+$answer{'webservergroup'} = 'bugzilla';
diff --git a/docker/files/my.cnf b/docker/files/my.cnf
new file mode 100644
index 000000000..b7e035ce5
--- /dev/null
+++ b/docker/files/my.cnf
@@ -0,0 +1,42 @@
+[mysql]
+max_allowed_packet=1G
+
+[mysqld]
+user = bugzilla
+default_storage_engine = InnoDB
+socket = /var/lib/mysql/mysql.sock
+pid_file = /var/lib/mysql/mysql.pid
+key_buffer_size = 32M
+myisam_recover = FORCE,BACKUP
+max_allowed_packet = 1G
+max_connect_errors = 1000000
+innodb = FORCE
+datadir = /var/lib/mysql
+character-set-server = utf8mb4
+collation-server = utf8mb4_general_ci
+
+tmp_table_size = 32M
+max_heap_table_size = 32M
+query_cache_type = 0
+query_cache_size = 0
+max_connections = 500
+thread_cache_size = 50
+#open_files_limit = 65535
+table_definition_cache = 1024
+table_open_cache = 2048
+
+innodb_flush_method = O_DIRECT
+innodb_log_files_in_group = 2
+innodb_log_file_size = 256M
+innodb_flush_log_at_trx_commit = 2
+innodb_file_per_table = 1
+innodb_buffer_pool_size = 1G
+innodb_flush_neighbors = 0
+innodb_flush_log_at_trx_commit = 2
+
+log_error = /var/lib/mysql/mysql-error.log
+log_queries_not_using_indexes = 0
+slow_query_log = 0
+slow_query_log_file = /var/lib/mysql/mysql-slow.log
+general_log = 0
+general_log_file = /var/lib/mysql/bmo_query.log
diff --git a/docker/files/rpm_list b/docker/files/rpm_list
new file mode 100644
index 000000000..3b155969b
--- /dev/null
+++ b/docker/files/rpm_list
@@ -0,0 +1,34 @@
+ImageMagick-perl
+bzip2
+ctags
+dbus-x11
+firefox
+gcc
+gcc-c++
+git
+graphviz
+java-1.7.0-openjdk
+make
+memcached
+mod_perl
+mod_perl-devel
+mpfr-devel
+mysql-community-server
+openssl-devel
+passwd
+patch
+patchutils
+perl-App-cpanminus
+perl-CPAN
+perl-DBD-MySQL
+perl-GD
+perl-GSSAPI
+perl-core
+postfix
+python-sphinx
+sudo
+supervisor
+tigervnc-server-minimal
+unzip
+vim-enhanced
+wget
diff --git a/docker/files/sudoers b/docker/files/sudoers
new file mode 100644
index 000000000..afd139090
--- /dev/null
+++ b/docker/files/sudoers
@@ -0,0 +1,9 @@
+Defaults env_reset
+Defaults env_keep = "COLORS DISPLAY HOSTNAME HISTSIZE INPUTRC KDEDIR LS_COLORS"
+Defaults env_keep += "MAIL PS1 PS2 QTDIR USERNAME LANG LC_ADDRESS LC_CTYPE"
+Defaults env_keep += "LC_COLLATE LC_IDENTIFICATION LC_MEASUREMENT LC_MESSAGES"
+Defaults env_keep += "LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER LC_TELEPHONE"
+Defaults env_keep += "LC_TIME LC_ALL LANGUAGE LINGUAS _XKB_CHARSET XAUTHORITY"
+Defaults secure_path = /sbin:/bin:/usr/sbin:/usr/bin
+root ALL=(ALL) ALL
+%wheel ALL=(ALL) NOPASSWD: ALL
diff --git a/docker/files/supervisord.conf b/docker/files/supervisord.conf
new file mode 100644
index 000000000..4a3d49fcd
--- /dev/null
+++ b/docker/files/supervisord.conf
@@ -0,0 +1,25 @@
+[supervisord]
+nodaemon=true
+logfile=/var/log/supervisor/supervisord.log
+logfile_maxbytes=50MB
+logfile_backups=10
+loglevel=debug
+pidfile=/var/run/supervisord.pid
+minfds=1024
+minprocs=200
+
+[program:httpd]
+command=/usr/sbin/httpd -DFOREGROUND
+
+[program:mysqld]
+command=/usr/bin/mysqld_safe
+
+[program:postfix]
+command = /usr/sbin/postfix start
+startsecs = 0
+autorestart = false
+
+[program:memcached]
+command=/usr/bin/memcached -u memcached
+stderr_logfile=/var/log/supervisor/memcached.log
+stdout_logfile=/var/log/supervisor/memcached.log