ok it builds now

master
Vitaliy Filippov 2016-12-30 17:07:41 +03:00
parent 072a6b9ca3
commit f60e88730c
6 changed files with 54 additions and 7 deletions

View File

@ -17,19 +17,18 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::=
libsoap-lite-perl libxmlrpc-lite-perl libjson-rpc-perl libjson-xs-perl libtext-csv-perl libhtml-strip-perl \
libtext-csv-xs-perl libspreadsheet-parseexcel-perl libspreadsheet-xlsx-perl \
liblingua-stem-snowball-perl libtheschwartz-perl \
libdaemon-generic-perl libhttp-server-simple-perl libnet-server-perl
libdaemon-generic-perl libhttp-server-simple-perl libnet-server-perl build-essential
ADD etc /etc
ADD home /home
ADD usr /usr
RUN service mysql start && echo "CREATE DATABASE bugzilla; \
GRANT ALL PRIVILEGES ON bugzilla.* TO bugzilla@localhost IDENTIFIED BY 'bugzilla'; \
FLUSH PRIVILEGES;" | mysql --defaults-file=/etc/mysql/debian.cnf
RUN cpan CGI Math::Random::Secure Sys::Sendfile Date::Parse Text::Wrap MIME::Parser
RUN cpan Module::Build CGI Math::Random::Secure Sys::Sendfile Date::Parse Text::Wrap MIME::Parser
RUN mv /var/lib/mysql /home/data/mysql && \
RUN mkdir /home/data && \
mv /var/lib/mysql /home/data/mysql && \
mv /var/lib/sphinxsearch /home/data/sphinxsearch && \
ln -s /home/data/mysql /var/lib/mysql && \
ln -s /home/data/sphinxsearch /var/lib/sphinxsearch && \
@ -47,7 +46,13 @@ RUN mv /var/lib/mysql /home/data/mysql && \
chown www-data:www-data /home/data/bugzilla && \
ln -s /home/data/bugzilla data
ADD localconfig /home/bugzilla/localconfig
ADD home /home
RUN service sphinxsearch start && \
service mysql start && \
cd /home/bugzilla && \
./checksetup.pl answers && \
rm answers
# Update image incrementally

27
README.md Normal file
View File

@ -0,0 +1,27 @@
# Bugzilla4Intranet Docker image
build it:
docker build -t bugzilla4intranet .
Run it:
docker run --name bz4i -p 8158:8157 -v /home/data -t -d bugzilla4intranet
Then point your browser to localhost:8158 and configure your Bugzilla.
# Docker cheatsheet
Some basic commands to work with the resulting container:
* list running containers: `docker ps`
* list all containers: `docker ps -a`
* list system images: `docker images`
* stop container: `docker stop mw4i`
* start container again: `docker start mw4i`
* run shell in the container: `docker exec -it mw4i bash`
* remove container: `docker rm <container_id>`
* remove image: `docker rmi <image_id>`
P.S: If you get "Cannot connect to the Docker daemon. Is the docker daemon running on this host?" error,
add your system user into `docker` group **and relogin**!

View File

@ -7,7 +7,8 @@ index bugzilla
rt_field = short_desc
rt_field = comments
rt_field = comments_private
docinfo = extern
rt_attr_uint = id
docinfo = inline
charset_table = 0..9, A..Z->a..z, a..z, U+410..U+42F->U+430..U+44F, U+430..U+44F
blend_chars = _, -, &, +, @, $
morphology = stem_enru

4
home/bugzilla/answers Normal file
View File

@ -0,0 +1,4 @@
$answer{'ADMIN_EMAIL'} = 'admin@bugzilla.4intra.net';
$answer{'ADMIN_PASSWORD'} = 'bugzilla';
$answer{'ADMIN_REALNAME'} = 'Bugzilla4Intranet admin';
$answer{'NO_PAUSE'} = 1;

10
home/start.sh Executable file
View File

@ -0,0 +1,10 @@
#!/bin/sh
export LC_ALL=ru_RU.UTF-8 LANG=ru_RU.UTF-8
service sphinxsearch start
service mysql start
service bugzilla start
# Keep container running
tail -fn0 /dev/null