initial commit of file from CVS for smeserver-bugzilla on Sat Sep 7 20:11:50 AEST 2024
This commit is contained in:
1
root/etc/e-smith/db/accounts/defaults/bugzilla/comment
Normal file
1
root/etc/e-smith/db/accounts/defaults/bugzilla/comment
Normal file
@@ -0,0 +1 @@
|
||||
Placeholder for bugzilla URL
|
1
root/etc/e-smith/db/accounts/defaults/bugzilla/type
Normal file
1
root/etc/e-smith/db/accounts/defaults/bugzilla/type
Normal file
@@ -0,0 +1 @@
|
||||
url
|
@@ -0,0 +1 @@
|
||||
bugzilla
|
@@ -0,0 +1 @@
|
||||
bugzilla
|
80
root/etc/e-smith/db/configuration/migrate/80bugzilla
Normal file
80
root/etc/e-smith/db/configuration/migrate/80bugzilla
Normal file
@@ -0,0 +1,80 @@
|
||||
{
|
||||
use MIME::Base64 qw(encode_base64);
|
||||
|
||||
my $service;
|
||||
my $rec;
|
||||
my $pw;
|
||||
|
||||
# Enable InnoDB (needed for Bugzilla)
|
||||
$service = 'mysqld';
|
||||
|
||||
$rec = $DB->get($service) || $DB->new_record($service, {type => 'service'});
|
||||
$rec->set_prop('InnoDB', 'enabled');
|
||||
|
||||
# Store the Bugzilla password in the configuration database (if not already there)
|
||||
$service = 'bugzilla';
|
||||
|
||||
$rec = $DB->get($service) || $DB->new_record($service, {type => 'service'});
|
||||
|
||||
$pw = $rec->prop('DbPassword');
|
||||
# return "" if $pw;
|
||||
|
||||
$adminpw = $rec->prop('AdminPassword');
|
||||
# return "" if $pw;
|
||||
|
||||
if (! $pw)
|
||||
{
|
||||
if ( open( RANDOM, "/dev/urandom" ) )
|
||||
{
|
||||
my $buf;
|
||||
# 57 bytes is a full line of Base64 coding, and contains
|
||||
# 456 bits of randomness - given a perfectly random /dev/random
|
||||
if ( read( RANDOM, $buf, 57 ) != 57 )
|
||||
{
|
||||
warn("Short read from /dev/random: $!");
|
||||
}
|
||||
else
|
||||
{
|
||||
$pw = encode_base64($buf);
|
||||
chomp $pw;
|
||||
}
|
||||
close RANDOM;
|
||||
}
|
||||
else
|
||||
{
|
||||
warn "Could not open /dev/urandom: $!";
|
||||
}
|
||||
|
||||
$rec->set_prop('DbPassword', $pw);
|
||||
}
|
||||
|
||||
if (! $adminpw)
|
||||
{
|
||||
if ( open( RANDOM, "/dev/urandom" ) )
|
||||
{
|
||||
my $buf;
|
||||
# 57 bytes is a full line of Base64 coding, and contains
|
||||
# 456 bits of randomness - given a perfectly random /dev/random
|
||||
if ( read( RANDOM, $buf, 57 ) != 57 )
|
||||
{
|
||||
warn("Short read from /dev/random: $!");
|
||||
}
|
||||
else
|
||||
{
|
||||
$adminpw = encode_base64($buf);
|
||||
chomp $adminpw;
|
||||
$adminpw = substr $adminpw, 0, 16;
|
||||
}
|
||||
close RANDOM;
|
||||
}
|
||||
else
|
||||
{
|
||||
warn "Could not open /dev/urandom: $!";
|
||||
}
|
||||
|
||||
$rec->set_prop('AdminPassword', $adminpw);
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
3
root/etc/e-smith/events/actions/bugzilla
Normal file
3
root/etc/e-smith/events/actions/bugzilla
Normal file
@@ -0,0 +1,3 @@
|
||||
#!/bin/bash
|
||||
|
||||
PERL5LIB="/usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi:/usr/lib/perl5/site_perl/5.8.5:/usr/lib/perl5/vendor_perl/5.8.5/i386-linux-thread-multi:/usr/lib/perl5/vendor_perl/5.8.5" /usr/share/bugzilla/checksetup.pl /etc/bugzilla.conf
|
0
root/etc/e-smith/events/bugzilla-update/.gitignore
vendored
Normal file
0
root/etc/e-smith/events/bugzilla-update/.gitignore
vendored
Normal file
0
root/etc/e-smith/events/post-upgrade/.gitignore
vendored
Normal file
0
root/etc/e-smith/events/post-upgrade/.gitignore
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
UID="root"
|
||||
GID="www"
|
||||
PERMS=0640
|
@@ -0,0 +1 @@
|
||||
PERMS=0540
|
1
root/etc/e-smith/templates/etc/bugzilla.conf/10nopause
Normal file
1
root/etc/e-smith/templates/etc/bugzilla.conf/10nopause
Normal file
@@ -0,0 +1 @@
|
||||
$answer\{'NO_PAUSE'\} = 1;
|
@@ -0,0 +1 @@
|
||||
$answer\{'ADMIN_EMAIL'\} = 'admin@{$DomainName}';
|
@@ -0,0 +1 @@
|
||||
$answer\{'ADMIN_REALNAME'\} = '';
|
@@ -0,0 +1 @@
|
||||
$answer\{'ADMIN_PASSWORD'\} = '{$bugzilla{'AdminPassword'}}';
|
@@ -0,0 +1,13 @@
|
||||
# If you are using Apache as your web server, Bugzilla can create .htaccess
|
||||
# files for you that will instruct Apache not to serve files that shouldn't
|
||||
# be accessed from the web browser (like your local configuration data and non-cgi
|
||||
# executable files). For this to work, the directory your Bugzilla
|
||||
# installation is in must be within the jurisdiction of a <Directory> block
|
||||
# in the httpd.conf file that has 'AllowOverride Limit' in it. If it has
|
||||
# 'AllowOverride All' or other options with Limit, that's fine.
|
||||
# (Older Apache installations may use an access.conf file to store these
|
||||
# <Directory> blocks.)
|
||||
# If this is set to 1, Bugzilla will create these files if they don't exist.
|
||||
# If this is set to 0, Bugzilla will not create these files.
|
||||
$create_htaccess = 1;
|
||||
|
@@ -0,0 +1,12 @@
|
||||
# This is the group your web server runs as.
|
||||
# If you have a Windows box, ignore this setting.
|
||||
# If you do not have access to the group your web server runs under,
|
||||
# set this to "". If you do set this to "", then your Bugzilla installation
|
||||
# will be _VERY_ insecure, because some files will be world readable/writable,
|
||||
# and so anyone who can get local access to your machine can do whatever they
|
||||
# want. You should only have this set to "" if this is a testing installation
|
||||
# and you cannot set this up any other way. YOU HAVE BEEN WARNED!
|
||||
# If you set this to anything other than "", you will need to run checksetup.pl
|
||||
# asroot, or as a user who is a member of the specified group.
|
||||
$webservergroup = 'www';
|
||||
|
@@ -0,0 +1,37 @@
|
||||
# What SQL database to use. Default is mysql. List of supported databases
|
||||
# can be obtained by listing Bugzilla/DB directory - every module corresponds
|
||||
# to one supported database and the name corresponds to a driver name.
|
||||
$db_driver = 'mysql';
|
||||
|
||||
# The DNS name of the host that the database server runs on.
|
||||
$db_host = 'localhost';
|
||||
|
||||
# The name of the database
|
||||
$db_name = '{$bugzilla{'DbDatabase'}}';
|
||||
|
||||
# Who we connect to the database as.
|
||||
$db_user = '{$bugzilla{'DbUser'}}';
|
||||
|
||||
# Enter your database password here. It's normally advisable to specify
|
||||
# a password for your bugzilla database user.
|
||||
# If you use apostrophe (') or a backslash (\) in your password, you'll
|
||||
# need to escape it by preceding it with a '\' character. (\') or (\)
|
||||
# (Far simpler just not to use those characters.)
|
||||
$db_pass = '{$bugzilla{'DbPassword'}}';
|
||||
|
||||
# Sometimes the database server is running on a non-standard port. If that's
|
||||
# the case for your database server, set this to the port number that your
|
||||
# database server is running on. Setting this to 0 means "use the default
|
||||
# port for my database server."
|
||||
$db_port = 0;
|
||||
|
||||
# MySQL Only: Enter a path to the unix socket for MySQL. If this is
|
||||
# blank, then MySQL's compiled-in default will be used. You probably
|
||||
# want that.
|
||||
$db_sock = '/var/lib/mysql/mariadb105.sock';
|
||||
|
||||
# Should checksetup.pl try to verify that your database setup is correct?
|
||||
# (with some combinations of database servers/Perl modules/moonphase this
|
||||
# doesn't work)
|
||||
$db_check = 1;
|
||||
|
12
root/etc/e-smith/templates/etc/bugzilla/localconfig/40index
Normal file
12
root/etc/e-smith/templates/etc/bugzilla/localconfig/40index
Normal file
@@ -0,0 +1,12 @@
|
||||
# With the introduction of a configurable index page using the
|
||||
# template toolkit, Bugzilla's main index page is now index.cgi.
|
||||
# Most web servers will allow you to use index.cgi as a directory
|
||||
# index, and many come preconfigured that way, but if yours doesn't
|
||||
# then you'll need an index.html file that provides redirection
|
||||
# to index.cgi. Setting $index_html to 1 below will allow
|
||||
# checksetup.pl to create one for you if it doesn't exist.
|
||||
# NOTE: checksetup.pl will not replace an existing file, so if you
|
||||
# wish to have checksetup.pl create one for you, you must
|
||||
# make sure that index.html doesn't already exist
|
||||
$index_html = 0;
|
||||
|
@@ -0,0 +1,6 @@
|
||||
# For some optional functions of Bugzilla (such as the pretty-print patch
|
||||
# viewer), we need the cvs binary to access files and revisions.
|
||||
# Because it's possible that this program is not in your path, you can specify
|
||||
# its location here. Please specify the full path to the executable.
|
||||
$cvsbin = '/usr/bin/cvs';
|
||||
|
@@ -0,0 +1,6 @@
|
||||
# For some optional functions of Bugzilla (such as the pretty-print patch
|
||||
# viewer), we need the interdiff binary to make diffs between two patches.
|
||||
# Because it's possible that this program is not in your path, you can specify
|
||||
# its location here. Please specify the full path to the executable.
|
||||
$interdiffbin = '/usr/bin/interdiff';
|
||||
|
@@ -0,0 +1,4 @@
|
||||
# The interdiff feature needs diff, so we have to have that path.
|
||||
# Please specify the directory name only; do not use trailing slash.
|
||||
$diffpath = '/usr/bin';
|
||||
|
@@ -0,0 +1,6 @@
|
||||
# This secret key is used by your installation for the creation and
|
||||
# validation of encrypted tokens to prevent unsolicited changes,
|
||||
# such as bug changes. A random string is generated by default.
|
||||
# It's very important that this key is kept secret. It also must be
|
||||
# very long.
|
||||
$site_wide_secret = '{ esmith::util::LdapPassword (); }';
|
@@ -0,0 +1,10 @@
|
||||
#!/bin/bash
|
||||
|
||||
DATABASE=`/sbin/e-smith/db configuration getprop bugzilla DbDatabase`
|
||||
USERNAME=`/sbin/e-smith/db configuration getprop bugzilla DbUser`
|
||||
PASSWORD=`/sbin/e-smith/db configuration getprop bugzilla DbPassword`
|
||||
|
||||
mysql105 -e "CREATE DATABASE IF NOT EXISTS $DATABASE DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;"
|
||||
mysql105 -e "USE mysql; GRANT SELECT,INSERT,UPDATE,DELETE,INDEX,ALTER,CREATE,DROP,REFERENCES,LOCK TABLES,CREATE TEMPORARY TABLES ON $DATABASE.* TO $USERNAME@localhost IDENTIFIED BY '$PASSWORD'; FLUSH PRIVILEGES;"
|
||||
|
||||
/etc/e-smith/events/actions/bugzilla
|
22
root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/86bugzilla
Executable file
22
root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/86bugzilla
Executable file
@@ -0,0 +1,22 @@
|
||||
#
|
||||
# httpd configuration settings for use with bugzilla.
|
||||
#
|
||||
|
||||
Alias /bugzilla /usr/share/bugzilla
|
||||
<Directory /usr/share/bugzilla>
|
||||
AddHandler cgi-script .cgi
|
||||
Options +ExecCGI
|
||||
Options +FollowSymLinks
|
||||
DirectoryIndex index.cgi
|
||||
AllowOverride Limit
|
||||
|
||||
Require {(($bugzilla{access} || 'public' ) eq "public" ) ? "all granted": "ip $localAccess $externalSSLAccess"; }
|
||||
|
||||
RewriteEngine on
|
||||
RewriteBase /bugzilla/
|
||||
RewriteRule ^index\.html$ index.cgi [T=application/x-httpd-cgi]
|
||||
|
||||
AddType application/vnd.mozilla.xul+xml .xul
|
||||
AddType application/rdf+xml .rdf
|
||||
|
||||
</Directory>
|
@@ -0,0 +1,93 @@
|
||||
[%# The contents of this file are subject to the Mozilla Public
|
||||
# License Version 1.1 (the "License"); you may not use this file
|
||||
# except in compliance with the License. You may obtain a copy of
|
||||
# the License at http://www.mozilla.org/MPL/
|
||||
#
|
||||
# Software distributed under the License is distributed on an "AS
|
||||
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
||||
# implied. See the License for the specific language governing
|
||||
# rights and limitations under the License.
|
||||
#
|
||||
# The Original Code is the Bugzilla Bug Tracking System.
|
||||
#
|
||||
# Contributor(s): Frédéric Buclin <LpSolit@gmail.com>
|
||||
#%]
|
||||
|
||||
[%# INTERFACE:
|
||||
# none
|
||||
#%]
|
||||
|
||||
[% PROCESS global/variables.none.tmpl %]
|
||||
|
||||
[% title = BLOCK %]Welcome to [% terms.Bugzilla %][% END %]
|
||||
|
||||
[% PROCESS global/header.html.tmpl
|
||||
title = title
|
||||
header_addl_info = "version $constants.BUGZILLA_VERSION"
|
||||
style_urls = [ 'skins/standard/index.css' ]
|
||||
%]
|
||||
|
||||
<div id="welcome-admin">
|
||||
<p>Welcome, [% user.identity FILTER html %].</p>
|
||||
|
||||
<p><b>Please change your password first by visiting <a href=userprefs.cgi?tab=account>Name
|
||||
and Password</a> tab on your personal preference page.</b></p>After that please proceed with
|
||||
the configuration settings below.
|
||||
|
||||
<p>You are seeing this page because some of the core parameters have not been set up yet.
|
||||
The goal of this page is to inform you about the last steps required to set up
|
||||
your installation correctly.</p>
|
||||
|
||||
<p>As an administrator, you have access to all administrative pages, accessible from
|
||||
the <a href="admin.cgi">Administration</a> link visible at the bottom of this page.
|
||||
This link will always be visible, on all pages. From there, you must visit at least
|
||||
the <a href="editparams.cgi">Parameters</a> page, from where you can set all important
|
||||
parameters for this installation; among others:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="editparams.cgi?section=core#maintainer">maintainer</a>, the person
|
||||
responsible for this installation if something is running wrong.</li>
|
||||
|
||||
<li><a href="editparams.cgi?section=core#urlbase">urlbase</a>, which is the URL
|
||||
pointing to this installation and which will be used in emails (which is also the
|
||||
reason you see this page: as long as this parameter is not set, you will see this
|
||||
page again and again).</li>
|
||||
|
||||
<li><a href="editparams.cgi?section=core#cookiepath">cookiepath</a> is important
|
||||
for your browser to manage your cookies correctly.</li>
|
||||
|
||||
<li><a href="editparams.cgi?section=core#utf8">utf8</a> will let you encode all
|
||||
texts into UTF-8, if desired (it is strongly recommended to keep this parameter
|
||||
turned on).</li>
|
||||
</ul>
|
||||
|
||||
<p>Also important are the following parameters:</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="editparams.cgi?section=auth#requirelogin">requirelogin</a>, if turned
|
||||
on, will protect your installation from users having no account on this installation.
|
||||
In other words, users who are not explicitly authenticated with a valid account
|
||||
cannot see any data. This is what you want if you want to keep your data private.</li>
|
||||
|
||||
<li><a href="editparams.cgi?section=auth#createemailregexp">createemailregexp</a>
|
||||
defines which users are allowed to create an account on this installation. If set
|
||||
to ".*" (the default), everybody is free to create his own account. If set to
|
||||
"@mycompany.com$", only users having an account @mycompany.com will be allowed to
|
||||
create an account. If left blank, users will not be able to create accounts themselves;
|
||||
only an administrator will be able to create one for them. If you want a private
|
||||
installation, you must absolutely set this parameter to something different from
|
||||
the default.</li>
|
||||
|
||||
<li><a href="editparams.cgi?section=mta#mail_delivery_method">mail_delivery_method</a>
|
||||
defines the method used to send emails, such as sendmail or SMTP. You have to set
|
||||
it correctly to send emails.</li>
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
After having set up all this, we recommend looking at [% terms.Bugzilla %]'s other
|
||||
parameters as well at some time so that you understand what they do and whether you
|
||||
want to modify their settings for your installation.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
[% PROCESS global/footer.html.tmpl %]
|
Reference in New Issue
Block a user