Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Thomas Leymonerie
slapos
Commits
20d2c4e5
Commit
20d2c4e5
authored
May 22, 2013
by
Cédric de Saint Martin
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/trac'
parents
6c87a67e
5d776684
Changes
18
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
1883 additions
and
0 deletions
+1883
-0
component/apache-wsgi/buildout.cfg
component/apache-wsgi/buildout.cfg
+43
-0
component/subversion/buildout.cfg
component/subversion/buildout.cfg
+43
-0
setup.py
setup.py
+1
-0
slapos/recipe/trac.py
slapos/recipe/trac.py
+183
-0
software/trac-svn/instance-mariadb.cfg
software/trac-svn/instance-mariadb.cfg
+224
-0
software/trac-svn/instance-trac.cfg
software/trac-svn/instance-trac.cfg
+494
-0
software/trac-svn/instance.cfg
software/trac-svn/instance.cfg
+12
-0
software/trac-svn/software.cfg
software/trac-svn/software.cfg
+379
-0
software/trac-svn/templates/apache.in
software/trac-svn/templates/apache.in
+132
-0
software/trac-svn/templates/create-svn-repo.sh.in
software/trac-svn/templates/create-svn-repo.sh.in
+26
-0
software/trac-svn/templates/git-http-backend.cgi.in
software/trac-svn/templates/git-http-backend.cgi.in
+6
-0
software/trac-svn/templates/gitweb.cgi.in
software/trac-svn/templates/gitweb.cgi.in
+3
-0
software/trac-svn/templates/gitweb.conf.in
software/trac-svn/templates/gitweb.conf.in
+9
-0
software/trac-svn/templates/post-revprop-change.in
software/trac-svn/templates/post-revprop-change.in
+6
-0
software/trac-svn/templates/trac-git-hook.in
software/trac-svn/templates/trac-git-hook.in
+4
-0
software/trac-svn/templates/trac-svn-hook.in
software/trac-svn/templates/trac-svn-hook.in
+64
-0
software/trac-svn/templates/trac.ini.in
software/trac-svn/templates/trac.ini.in
+237
-0
software/trac-svn/templates/trac.wsgi.in
software/trac-svn/templates/trac.wsgi.in
+17
-0
No files found.
component/apache-wsgi/buildout.cfg
0 → 100644
View file @
20d2c4e5
[buildout]
extends =
../apache/buildout.cfg
../python-2.7/buildout.cfg
../bzip2/buildout.cfg
../gdbm/buildout.cfg
../gettext/buildout.cfg
../libexpat/buildout.cfg
../ncurses/buildout.cfg
../openssl/buildout.cfg
../readline/buildout.cfg
../sqlite3/buildout.cfg
../zlib/buildout.cfg
../file/buildout.cfg
parts =
apache-wsgi
[python2.7]
configure-options =
--enable-shared
--disable-static
--enable-ipv6
--enable-unicode=ucs4
--with-system-expat
--with-threads
environment =
CPPFLAGS=-I${zlib:location}/include -I${readline:location}/include -I${libexpat:location}/include -I${ncurses:location}/include -I${ncurses:location}/include/ncursesw -I${bzip2:location}/include -I${gdbm:location}/include -I${openssl:location}/include -I${sqlite3:location}/include -I${gettext:location}/include
LDFLAGS=-L${zlib:location}/lib -L${readline:location}/lib -L${libexpat:location}/lib -L${ncurses:location}/lib -L${bzip2:location}/lib -L${gdbm:location}/lib -L${openssl:location}/lib -L${sqlite3:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${readline:location}/lib -Wl,-rpath=${libexpat:location}/lib -Wl,-rpath=${ncurses:location}/lib -Wl,-rpath=${bzip2:location}/lib -Wl,-rpath=${gdbm:location}/lib -Wl,-rpath=${openssl:location}/lib -Wl,-rpath=${sqlite3:location}/lib -L${gettext:location}/lib -Wl,-rpath=${gettext:location}/lib -Wl,-rpath=${file:location}/lib
LD_RUN_PATH=${buildout:parts-directory}/${:_buildout_section_name_}/lib
[apache-wsgi]
recipe = hexagonit.recipe.cmmi
url = http://modwsgi.googlecode.com/files/mod_wsgi-3.4.tar.gz
md5sum = f42d69190ea0c337ef259cbe8d94d985
configure-options =
--with-apxs=${apache:location}/bin/apxs
--with-python=${python2.7:location}/bin/python2.7
environment =
CPPFLAGS = -I${python2.7:location}/include/python2.7
LDFLAGS = -L${python2.7:location}/lib
component/subversion/buildout.cfg
View file @
20d2c4e5
...
@@ -10,6 +10,7 @@ extends =
...
@@ -10,6 +10,7 @@ extends =
../pkgconfig/buildout.cfg
../pkgconfig/buildout.cfg
../sqlite3/buildout.cfg
../sqlite3/buildout.cfg
../zlib/buildout.cfg
../zlib/buildout.cfg
../swig/buildout.cfg
parts =
parts =
subversion
subversion
...
@@ -59,3 +60,45 @@ environment =
...
@@ -59,3 +60,45 @@ environment =
PKG_CONFIG_PATH=${apache:location}/lib/pkgconfig:${sqlite3:location}/lib/pkgconfig:${openssl:location}/lib/pkgconfig:${neon:location}/lib/pkgconfig
PKG_CONFIG_PATH=${apache:location}/lib/pkgconfig:${sqlite3:location}/lib/pkgconfig:${openssl:location}/lib/pkgconfig:${neon:location}/lib/pkgconfig
CPPFLAGS=-I${libexpat:location}/include -I${libuuid:location}/include
CPPFLAGS=-I${libexpat:location}/include -I${libuuid:location}/include
LDFLAGS=-L${libexpat:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${sqlite3:location}/lib -Wl,-rpath=${neon:location}/lib -Wl,-rpath=${apache:location}/lib -L${libuuid:location}/lib -Wl,-rpath=${libuuid:location}/lib
LDFLAGS=-L${libexpat:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${sqlite3:location}/lib -Wl,-rpath=${neon:location}/lib -Wl,-rpath=${apache:location}/lib -L${libuuid:location}/lib -Wl,-rpath=${libuuid:location}/lib
[subversion-1.9]
recipe = hexagonit.recipe.cmmi
url = http://www.apache.org/dist/subversion/subversion-1.7.9.tar.gz
md5sum = dfb083e8bfac88aa28d606168b08e4ff
configure-options =
--disable-static
--with-apr=${apache:location}/bin/apr-1-config
--with-apr-util=${apache:location}/bin/apu-1-config
--with-apxs=${apache:location}/bin/apxs
--with-zlib=${zlib:location}
--with-sqlite=${sqlite3:location}
--with-neon=${neon:location}
--with-swig=${swig:location}/bin/swig
--without-berkeley-db
--without-sasl
--without-apr_memcache
--without-gnome-keyring
--without-kwallet
--without-jdk
--without-jikes
--without-junit
--without-ctypesgen
--without-ruby-sitedir
--without-ruby-test-verbose
--disable-nls
# it seems that parallel build sometimes fails.
make-options =
-j1
make-targets =
install
swig-py
install-swig-py
environment =
PATH=${pkgconfig:location}/bin:${neon:location}/bin:%(PATH)s
PKG_CONFIG_PATH=${apache:location}/lib/pkgconfig:${sqlite3:location}/lib/pkgconfig:${openssl:location}/lib/pkgconfig:${neon:location}/lib/pkgconfig
CPPFLAGS=-I${libexpat:location}/include -I${libuuid:location}/include
LDFLAGS=-L${libexpat:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${sqlite3:location}/lib -Wl,-rpath=${neon:location}/lib -Wl,-rpath=${apache:location}/lib -L${libuuid:location}/lib -Wl,-rpath=${libuuid:location}/lib
setup.py
View file @
20d2c4e5
...
@@ -195,6 +195,7 @@ setup(name=name,
...
@@ -195,6 +195,7 @@ setup(name=name,
'stunnel = slapos.recipe.stunnel:Recipe'
,
'stunnel = slapos.recipe.stunnel:Recipe'
,
'symbolic.link = slapos.recipe.symbolic_link:Recipe'
,
'symbolic.link = slapos.recipe.symbolic_link:Recipe'
,
'tidstorage = slapos.recipe.tidstorage:Recipe'
,
'tidstorage = slapos.recipe.tidstorage:Recipe'
,
'trac = slapos.recipe.trac:Recipe'
,
'urlparse = slapos.recipe._urlparse:Recipe'
,
'urlparse = slapos.recipe._urlparse:Recipe'
,
'uuid = slapos.recipe._uuid:Recipe'
,
'uuid = slapos.recipe._uuid:Recipe'
,
'vifib = slapos.recipe.vifib:Recipe'
,
'vifib = slapos.recipe.vifib:Recipe'
,
...
...
slapos/recipe/trac.py
0 → 100644
View file @
20d2c4e5
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (c) 2010 Vifib SARL and Contributors. All Rights Reserved.
#
# WARNING: This program as such is intended to be used by professional
# programmers who take the whole responsibility of assessing all potential
# consequences resulting from its eventual inadequacies and bugs
# End users who are looking for a ready-to-use solution with commercial
# guarantees and support are strongly adviced to contract a Free Software
# Service Company
#
# This program is Free Software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 3
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
##############################################################################
import
os
import
sys
import
subprocess
import
shutil
import
json
from
slapos.recipe.librecipe
import
GenericBaseRecipe
class
Recipe
(
GenericBaseRecipe
):
def
__init__
(
self
,
buildout
,
name
,
options
):
pythonPath
=
""
for
eggs
in
options
[
'eggs-dirs'
].
splitlines
():
if
eggs
:
for
item
in
os
.
listdir
(
eggs
):
path
=
os
.
path
.
join
(
eggs
,
item
)
pythonPath
=
path
+
":"
+
pythonPath
options
[
'python_path'
]
=
pythonPath
options
[
'wsgi-dir'
]
=
os
.
path
.
join
(
options
[
'site-dir'
].
strip
(),
'apache'
)
options
[
'git-dir'
]
=
os
.
path
.
join
(
options
[
'site-dir'
].
strip
(),
'git'
)
options
[
'svn-dir'
]
=
os
.
path
.
join
(
options
[
'site-dir'
].
strip
(),
'svn'
)
return
GenericBaseRecipe
.
__init__
(
self
,
buildout
,
name
,
options
)
def
install
(
self
):
install_path
=
[]
env
=
os
.
environ
env
[
'LD_LIBRARY_PATH'
]
=
self
.
options
[
'python-lib'
]
project_dir
=
self
.
options
[
'site-dir'
].
strip
()
trac_admin
=
self
.
options
[
'trac-admin'
].
strip
()
admin
=
self
.
options
[
'admin-user'
].
strip
()
passwd
=
self
.
options
[
'admin-password'
].
strip
()
config
=
os
.
path
.
join
(
project_dir
,
'conf/trac.ini'
)
filestat
=
self
.
options
[
'file-status'
].
strip
()
self
.
logger
.
info
(
"Checking if trac project is not installed..."
)
if
os
.
path
.
exists
(
filestat
):
os
.
unlink
(
filestat
)
if
not
os
.
path
.
exists
(
project_dir
):
self
.
logger
.
info
(
"Starting trac project installation at %s"
%
project_dir
)
trac_args
=
[
trac_admin
,
project_dir
,
'initenv'
]
db_string
=
"mysql://%s:%s@%s:%s/%s"
%
(
self
.
options
[
'mysql-username'
].
strip
(),
self
.
options
[
'mysql-password'
].
strip
(),
self
.
options
[
'mysql-host'
].
strip
(),
self
.
options
[
'mysql-port'
].
strip
(),
self
.
options
[
'mysql-database'
].
strip
()
)
process_install
=
subprocess
.
Popen
(
trac_args
,
stdout
=
subprocess
.
PIPE
,
stdin
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
STDOUT
,
env
=
env
)
process_install
.
stdin
.
write
(
'%s
\
n
%s
\
n
'
%
(
self
.
options
[
'project'
].
strip
(),
db_string
))
result
=
process_install
.
communicate
()[
0
]
process_install
.
stdin
.
close
()
if
process_install
.
returncode
is
None
or
process_install
.
returncode
!=
0
:
if
os
.
path
.
exists
(
project_dir
):
shutil
.
rmtree
(
project_dir
)
self
.
logger
.
error
(
"Failed to initialize Trac.
\
n
The error was: %s"
%
result
)
return
[]
os
.
mkdir
(
self
.
options
[
'git-dir'
])
os
.
mkdir
(
self
.
options
[
'svn-dir'
])
os
.
mkdir
(
self
.
options
[
'wsgi-dir'
])
os
.
unlink
(
config
)
shutil
.
copy
(
self
.
options
[
'trac-ini'
].
strip
(),
config
)
shutil
.
copy
(
self
.
options
[
'trac-wsgi'
].
strip
(),
os
.
path
.
join
(
self
.
options
[
'wsgi-dir'
],
'trac.wsgi'
))
else
:
self
.
logger
.
info
(
"The directory %s already exist, skip project installation"
%
project_dir
)
trac_args
=
[
trac_admin
,
project_dir
,
'upgrade'
]
process_upgrade
=
subprocess
.
Popen
(
trac_args
,
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
STDOUT
,
env
=
env
)
result
=
process_upgrade
.
communicate
()[
0
]
if
process_upgrade
.
returncode
is
None
or
process_upgrade
.
returncode
!=
0
:
self
.
logger
.
error
(
"Failed to upgrade Trac.
\
n
The error was: %s"
%
result
)
return
[]
#Add All grant to admin user
self
.
logger
.
info
(
"Granting admin rights to the admin user."
)
trac_grant
=
[
trac_admin
,
project_dir
,
"permission add %s TRAC_ADMIN"
%
admin
]
process
=
subprocess
.
Popen
(
trac_grant
,
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
STDOUT
,
env
=
env
)
result
=
process
.
communicate
()[
0
]
if
process
.
returncode
is
None
or
process
.
returncode
!=
0
:
raise
Exception
(
"Failed to execute Trac-admin.
\
n
The error was: %s"
%
result
)
self
.
logger
.
info
(
"Copying additional plugins into plugins directory"
)
plugins_dir
=
os
.
path
.
join
(
project_dir
,
"plugins"
)
for
item
in
os
.
listdir
(
self
.
options
[
'plugins-egg-dir'
].
strip
()):
source
=
os
.
path
.
join
(
self
.
options
[
'plugins-egg-dir'
].
strip
(),
item
)
destination
=
os
.
path
.
join
(
plugins_dir
,
item
)
if
not
os
.
path
.
exists
(
destination
):
shutil
.
copytree
(
source
,
destination
)
svn_list
=
json
.
loads
(
self
.
options
.
get
(
'svn-project-list'
,
'{}'
))
for
svn_repo
in
svn_list
:
svn_repo_path
=
os
.
path
.
join
(
self
.
options
[
'svn-dir'
],
svn_repo
)
if
not
os
.
path
.
exists
(
svn_repo_path
):
self
.
logger
.
info
(
"Initializing %s SVN repository..."
%
svn_repo
)
svn_args
=
[
self
.
options
[
'svn-repo-script'
],
project_dir
,
svn_repo
,
svn_list
[
svn_repo
]]
process
=
subprocess
.
Popen
(
svn_args
,
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
STDOUT
)
result
=
process
.
communicate
()[
0
]
if
process
.
returncode
is
None
or
process
.
returncode
!=
0
:
shutil
.
rmtree
(
svn_repo_path
)
raise
Exception
(
"Failed to create repository.
\
n
The error was: %s"
%
result
)
shutil
.
copy
(
self
.
options
[
'trac-svn-hook'
].
strip
(),
os
.
path
.
join
(
svn_repo_path
,
'hooks/post-commit'
))
shutil
.
copy
(
self
.
options
[
'post-revprop-change'
].
strip
(),
os
.
path
.
join
(
svn_repo_path
,
'hooks/post-revprop-change'
))
self
.
logger
.
info
(
"Finished initializing %s reposiroty"
%
svn_repo
)
repolist
=
json
.
loads
(
self
.
options
.
get
(
'git-project-list'
,
'{}'
))
for
repo
,
desc
in
repolist
.
iteritems
():
absolute_path
=
os
.
path
.
join
(
self
.
options
[
'git-dir'
],
'%s.git'
%
repo
)
if
not
os
.
path
.
exists
(
absolute_path
):
self
.
logger
.
info
(
"Initializing %s GIT repository..."
%
repo
)
subprocess
.
check_call
([
self
.
options
[
'git-binary'
],
'init'
,
'--bare'
,
absolute_path
])
subprocess
.
check_call
([
trac_admin
,
project_dir
,
'repository'
,
'add'
,
repo
,
absolute_path
,
'git'
],
env
=
env
)
subprocess
.
check_call
([
trac_admin
,
project_dir
,
'repository'
,
'resync'
,
repo
],
env
=
env
)
# XXX: Hardcoded path
shutil
.
copy
(
self
.
options
[
'trac-git-hook'
].
strip
(),
os
.
path
.
join
(
absolute_path
,
'hooks/post-commit'
))
description_filename
=
os
.
path
.
join
(
absolute_path
,
'description'
)
with
open
(
description_filename
,
'w'
)
as
description_file
:
description_file
.
write
(
desc
)
user_list
=
json
.
loads
(
self
.
options
.
get
(
'user-list'
,
'{}'
))
fd
=
open
(
os
.
path
.
join
(
project_dir
,
'svnpasswd'
),
'w'
)
fd
.
write
(
"[users]
\
n
%s = %s"
%
(
admin
,
passwd
))
os
.
system
(
"%s -cb %s %s %s"
%
(
self
.
options
[
'htpasswd'
],
self
.
options
[
'passwd-file'
],
admin
,
passwd
)
)
for
user
in
user_list
:
self
.
logger
.
info
(
"Creating or updating user %s ..."
%
user
)
user_args
=
[
self
.
options
[
'htpasswd'
],
'-b'
,
self
.
options
[
'passwd-file'
],
user
,
user_list
[
user
]]
process
=
subprocess
.
Popen
(
user_args
,
stdout
=
subprocess
.
PIPE
,
stderr
=
subprocess
.
STDOUT
)
result
=
process
.
communicate
()[
0
]
if
process
.
returncode
is
None
or
process
.
returncode
!=
0
:
raise
Exception
(
"Failed to create user %s.
\
n
The error was: %s"
%
(
user
,
result
))
fd
.
write
(
"
\
n
%s = %s"
%
(
user
,
user_list
[
user
]))
fd
.
close
()
open
(
filestat
,
"w"
).
write
(
"done."
)
return
install_path
software/trac-svn/instance-mariadb.cfg
0 → 100644
View file @
20d2c4e5
[buildout]
parts =
urls
mariadb
stunnel
certificate-authority
ca-stunnel
logrotate
logrotate-entry-mariadb
logrotate-entry-stunnel
logrotate-entry-cron
cron
cron-entry-logrotate
slapmonitor
slapreport
gzip-binary = ${gzip:location}/bin/gzip
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
[rootdirectory]
recipe = slapos.cookbook:mkdirectory
etc = $${buildout:directory}/etc/
var = $${buildout:directory}/var/
srv = $${buildout:directory}/srv/
bin = $${buildout:directory}/bin/
[basedirectory]
recipe = slapos.cookbook:mkdirectory
log = $${rootdirectory:var}/log/
scripts = $${rootdirectory:etc}/run/
services = $${rootdirectory:etc}/service/
run = $${rootdirectory:var}/run/
backup = $${rootdirectory:srv}/backup/
promises = $${rootdirectory:etc}/promise/
[directory]
recipe = slapos.cookbook:mkdirectory
cron-entries = $${rootdirectory:etc}/cron.d/
crontabs = $${rootdirectory:etc}/crontabs/
cronstamps = $${rootdirectory:etc}/cronstamps/
ca-dir = $${rootdirectory:srv}/ssl/
mariadb-data = $${rootdirectory:srv}/mariadb/
logrotate-backup = $${basedirectory:backup}/logrotate/
stunnel-conf = $${rootdirectory:etc}/stunnel/
logrotate-entries = $${rootdirectory:etc}/logrotate.d/
[urls]
recipe = slapos.cookbook:publish
url = mysqls://$${mariadb:user}:$${mariadb:password}@[$${stunnel:remote-host}]:$${stunnel:remote-port}/$${mariadb:database}
[mariadb]
recipe = slapos.cookbook:mysql
# Options
recovering = false
user = trac
port = 3306
password = $${mysql-password:passwd}
ip = $${slap-network-information:local-ipv4}
database = trac
# Paths
wrapper = $${basedirectory:services}/mariadb
update-wrapper = $${basedirectory:scripts}/mariadb_update
logrotate-post = $${rootdirectory:bin}/mariadb_post_logrotate
data-directory = $${directory:mariadb-data}
pid-file = $${basedirectory:run}/mariadb.pid
socket = $${basedirectory:run}/mariadb.sock
error-log = $${basedirectory:log}/mariadb_error.log
conf-file = $${rootdirectory:etc}/mariadb.cnf
promise = $${basedirectory:promises}/mysql
# Binary information
mysql-base-directory = ${mariadb:location}
mysql-binary = ${mariadb:location}/bin/mysql
mysql-install-binary = ${mariadb:location}/scripts/mysql_install_db
mysql-upgrade-binary = ${mariadb:location}/bin/mysql_upgrade
mysqld-binary = ${mariadb:location}/bin/mysqld
[mysql-password]
recipe = slapos.cookbook:generate.password
storage-path = $${rootdirectory:etc}/.passwd
bytes = 4
[slapmonitor]
recipe = slapos.cookbook:slapmonitor
pid-file = $${basedirectory:run}/mariadb.pid
database-path = $${basedirectory:log}/slapmonitor.db
shell-path = ${dash:location}/bin/dash
slapmonitor-path = ${buildout:bin-directory}/slapmonitor
path = $${basedirectory:scripts}/slapmonitor
[slapreport]
recipe = slapos.cookbook:slapreport
pid-file = $${basedirectory:run}/mariadb.pid
consumption-log-path = $${basedirectory:log}/instance_consumption.log
database-path = $${basedirectory:log}/slapmonitor.db
logbox-ip = 87.98.152.12
logbox-port = 5122
logbox-user = admin
logbox-passwd = passer
shell-path = ${dash:location}/bin/dash
slapreport-path = ${buildout:bin-directory}/slapreport
path = $${basedirectory:scripts}/slapreport
[certificate-authority]
recipe = slapos.cookbook:certificate_authority
openssl-binary = ${openssl:location}/bin/openssl
ca-dir = $${directory:ca-dir}
requests-directory = $${cadirectory:requests}
wrapper = $${basedirectory:services}/ca
ca-private = $${cadirectory:private}
ca-certs = $${cadirectory:certs}
ca-newcerts = $${cadirectory:newcerts}
ca-crl = $${cadirectory:crl}
[cadirectory]
recipe = slapos.cookbook:mkdirectory
requests = $${directory:ca-dir}/requests/
private = $${directory:ca-dir}/private/
certs = $${directory:ca-dir}/certs/
newcerts = $${directory:ca-dir}/newcerts/
crl = $${directory:ca-dir}/crl/
[ca-stunnel]
<= certificate-authority
recipe = slapos.cookbook:certificate_authority.request
executable = $${stunnel:wrapper}
wrapper = $${basedirectory:services}/stunnel
key-file = $${stunnel:key-file}
cert-file = $${stunnel:cert-file}
[stunnel]
recipe = slapos.cookbook:stunnel
stunnel-binary = ${stunnel:location}/bin/stunnel
wrapper = $${rootdirectory:bin}/stunnel
log-file = $${basedirectory:log}/stunnel.log
config-file = $${directory:stunnel-conf}/stunnel.conf
key-file = $${directory:stunnel-conf}/stunnel.key
cert-file = $${directory:stunnel-conf}/stunnel.crt
pid-file = $${basedirectory:run}/stunnel.pid
local-host = $${mariadb:ip}
local-port = $${mariadb:port}
remote-host = $${slap-network-information:global-ipv6}
remote-port = 6446
client = false
post-rotate-script = $${rootdirectory:bin}/stunnel_post_rotate
[logrotate]
recipe = slapos.cookbook:logrotate
# Binaries
logrotate-binary = ${logrotate:location}/usr/sbin/logrotate
gzip-binary = $${buildout:gzip-binary}
gunzip-binary = ${gzip:location}/bin/gunzip
# Directories
wrapper = $${rootdirectory:bin}/logrotate
conf = $${rootdirectory:etc}/logrotate.conf
logrotate-entries = $${directory:logrotate-entries}
backup = $${directory:logrotate-backup}
state-file = $${rootdirectory:srv}/logrotate.status
[logrotate-entry-mariadb]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = mariadb
log = $${mariadb:error-log}
frequency = daily
rotate-num = 30
post = $${mariadb:logrotate-post}
sharedscripts = true
notifempty = true
create = true
[logrotate-entry-stunnel]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = stunnel
log = $${stunnel:log-file}
frequency = daily
rotate-num = 30
notifempty = true
create = true
post = $${stunnel:post-rotate-script}
[logrotate-entry-cron]
<= logrotate
recipe =slapos.cookbook:logrotate.d
name = crond
log = $${cron-simplelogger:log}
frequency = daily
rotate-num = 30
notifempty = true
create = true
[cron]
recipe = slapos.cookbook:cron
dcrond-binary = ${dcron:location}/sbin/crond
cron-entries = $${directory:cron-entries}
crontabs = $${directory:crontabs}
cronstamps = $${directory:cronstamps}
catcher = $${cron-simplelogger:wrapper}
binary = $${basedirectory:services}/crond
[cron-simplelogger]
recipe = slapos.cookbook:simplelogger
wrapper = $${rootdirectory:bin}/cron_simplelogger
log = $${basedirectory:log}/crond.log
[cron-entry-logrotate]
<= cron
recipe = slapos.cookbook:cron.d
name = logrotate
frequency = 0 0 * * *
command = $${logrotate:wrapper}
[slap-parameter]
#Default value if no ssh parameters specified
logbox-ip =
logbox-port =
logbox-user =
logbox-passwd =
\ No newline at end of file
software/trac-svn/instance-trac.cfg
0 → 100644
View file @
20d2c4e5
[buildout]
parts =
certificate-authority
ca-stunnel
logrotate
logrotate-entry-stunnel
logrotate-entry-apache
cron
cron-entry-logrotate
trac-config
trac-git-hook-script
trac-svn-hook-script
post-revprop-change-script
gitweb-conf
httpd
gitdaemon
promise
ca-shellinabox
frontend-promise
content-promise
publish-connection-informations
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
#----------------
#--
#-- Creation of all needed directories.
[rootdirectory]
recipe = slapos.cookbook:mkdirectory
etc = $${buildout:directory}/etc
var = $${buildout:directory}/var
srv = $${buildout:directory}/srv
bin = $${buildout:directory}/bin
tmp = $${buildout:directory}/tmp
[basedirectory]
recipe = slapos.cookbook:mkdirectory
log = $${rootdirectory:var}/log
services = $${rootdirectory:etc}/service
run = $${rootdirectory:var}/run
backup = $${rootdirectory:srv}/backup
promises = $${rootdirectory:etc}/promise
[directory]
recipe = slapos.cookbook:mkdirectory
cron-entries = $${rootdirectory:etc}/cron.d
crontabs = $${rootdirectory:etc}/crontabs
cronstamps = $${rootdirectory:etc}/cronstamps
ca-dir = $${rootdirectory:srv}/ssl
httpd-log = $${basedirectory:log}/apache
logrotate-entries = $${rootdirectory:etc}/logrotate.d
logrotate-backup = $${basedirectory:backup}/logrotate
tracconfig = $${rootdirectory:srv}
stunnel-conf = $${rootdirectory:etc}/stunnel
shellinabox = $${rootdirectory:srv}/shellinabox/
[cadirectory]
recipe = slapos.cookbook:mkdirectory
requests = $${directory:ca-dir}/requests
private = $${directory:ca-dir}/private
certs = $${directory:ca-dir}/certs
newcerts = $${directory:ca-dir}/newcerts
crl = $${directory:ca-dir}/crl
#----------------
#--
#-- Deploy cron.
[cron]
recipe = slapos.cookbook:cron
dcrond-binary = ${dcron:location}/sbin/crond
cron-entries = $${directory:cron-entries}
crontabs = $${directory:crontabs}
cronstamps = $${directory:cronstamps}
catcher = $${cron-simplelogger:wrapper}
binary = $${basedirectory:services}/crond
[cron-simplelogger]
recipe = slapos.cookbook:simplelogger
wrapper = $${rootdirectory:bin}/cron_simplelogger
log = $${basedirectory:log}/crond.log
#----------------
#--
#-- Deploy logrotate.
[cron-entry-logrotate]
<= cron
recipe = slapos.cookbook:cron.d
name = logrotate
frequency = 0 0 * * *
command = $${logrotate:wrapper}
[logrotate]
recipe = slapos.cookbook:logrotate
# Binaries
logrotate-binary = ${logrotate:location}/usr/sbin/logrotate
gzip-binary = ${gzip:location}/bin/gzip
gunzip-binary = ${gzip:location}/bin/gunzip
# Directories
wrapper = $${rootdirectory:bin}/logrotate
conf = $${rootdirectory:etc}/logrotate.conf
logrotate-entries = $${directory:logrotate-entries}
backup = $${directory:logrotate-backup}
state-file = $${rootdirectory:srv}/logrotate.status
#----------------
#--
#-- Deploy stunnel.
[stunnel]
recipe = slapos.cookbook:stunnel
client = true
stunnel-binary = ${stunnel:location}/bin/stunnel
remote-host = $${mariadb-urlparse:host}
remote-port = $${mariadb-urlparse:port}
local-host = $${slap-network-information:local-ipv4}
local-port = 3306
log-file = $${basedirectory:log}/stunnel.log
config-file = $${directory:stunnel-conf}/stunnel.conf
key-file = $${directory:stunnel-conf}/stunnel.key
cert-file = $${directory:stunnel-conf}/stunnel.crt
pid-file = $${basedirectory:run}/stunnel.pid
wrapper = $${rootdirectory:bin}/raw_stunnel
post-rotate-script = $${rootdirectory:bin}/stunnel_post_rotate
[logrotate-entry-stunnel]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = stunnel
log = $${stunnel:log-file}
frequency = daily
rotate-num = 30
notifempty = true
create = true
post = $${stunnel:post-rotate-script}
#----------------
#--
#-- Certificate stuff.
[certificate-authority]
recipe = slapos.cookbook:certificate_authority
openssl-binary = ${openssl:location}/bin/openssl
ca-dir = $${directory:ca-dir}
requests-directory = $${cadirectory:requests}
wrapper = $${basedirectory:services}/ca
ca-private = $${cadirectory:private}
ca-certs = $${cadirectory:certs}
ca-newcerts = $${cadirectory:newcerts}
ca-crl = $${cadirectory:crl}
[ca-stunnel]
<= certificate-authority
recipe = slapos.cookbook:certificate_authority.request
executable = $${stunnel:wrapper}
wrapper = $${basedirectory:services}/stunnel
key-file = $${stunnel:key-file}
cert-file = $${stunnel:cert-file}
#----------------
#--
#-- Request MariaDB instance and parse its URL.
[request-mariadb]
<= slap-connection
recipe = slapos.cookbook:request
name = MariaDB
software-url = $${slap-connection:software-release-url}
software-type = mariadb
return = url
sla = computer_guid
sla-computer_guid = $${slap-connection:computer-id}
[mariadb-urlparse]
recipe = slapos.cookbook:urlparse
url = $${request-mariadb:connection-url}
#----------------
#--
#-- Deploy Apache + PHP application.
[httpd-conf]
recipe = slapos.recipe.template
url = ${template-httpd-conf:location}/${template-httpd-conf:filename}
output = $${rootdirectory:etc}/apache.conf
document_root = $${rootdirectory:srv}/site/
wsgi_location = $${rootdirectory:srv}/site/apache
gitweb-static-dir = ${gitweb:location}/share/gitweb/static/
gitweb-script = $${gitweb-cgi:output}
git-http-backend = $${git-http-backend-cgi:output}
cgid-sock = $${basedirectory:run}/cgid.sock
pid_file = $${basedirectory:run}/apache.pid
lock_file = $${basedirectory:run}/apache.lock
ip = $${slap-network-information:global-ipv6}
port = 8080
error_log = $${directory:httpd-log}/error.log
access_log = $${directory:httpd-log}/access.log
[trac-config]
recipe = slapos.recipe.template
url = ${tracIni:location}/${tracIni:filename}
output = $${directory:tracconfig}/trac-config-model.ini
mode = 0600
project_dir = $${rootdirectory:srv}/site
#project_url = http://[$${slap-network-information:global-ipv6}]:8080
project_url = $${request-frontend:connection-site_url}
trac_plugins = $${:project_dir}/plugins
git_bin = ${git:location}/bin/git
git_project_base = $${:project_dir}/git
git_project_list =
git_url = $${:project_url}git
admin_email = $${slap-parameter:admin-email}
project_description = $${slap-parameter:project-desc}
project_footer = $${slap-parameter:project-footer}
project_name = $${slap-parameter:project-name}
#MySQL informations
mysql_username = $${mariadb-urlparse:username}
mysql_password = $${mariadb-urlparse:password}
mysql_database = $${mariadb-urlparse:path}
mysql_host = $${stunnel:local-host}
mysql_port = $${stunnel:local-port}
[trac-wsgi]
recipe = slapos.recipe.template
url = ${tracWsgi:location}/${tracWsgi:filename}
output = $${directory:tracconfig}/trac.wsgi
mode = 0700
trac_env = $${trac-config:project_dir}
python_bin = ${python2.7:location}/bin/python2.7
[trac-svn-hook-script]
recipe = slapos.recipe.template
url = ${trac-svn-hook:location}/${trac-svn-hook:filename}
output = $${directory:tracconfig}/trac-svn-hook
mode = 0700
trac_env = $${trac-config:project_dir}
trac_admin = ${buildout:bin-directory}
python_bin = ${python2.7:location}/bin
python_lib = ${python2.7:location}/lib
svn_python = ${subversion-1.9:location}/lib/svn-python
[trac-git-hook-script]
recipe = slapos.recipe.template
url = ${trac-git-hook:location}/${trac-git-hook:filename}
output = $${directory:tracconfig}/trac-git-hook
mode = 0700
git_bin = ${git:location}/bin/git
trac_admin = ${buildout:bin-directory}/trac-admin
trac_env = $${trac-config:project_dir}
[post-revprop-change-script]
recipe = slapos.recipe.template
url = ${post-revprop-change:location}/${post-revprop-change:filename}
output = $${directory:tracconfig}/post-revprop-change
mode = 0700
trac_svn_hook = $${trac-svn-hook-script:output}
[trac-svnrepo-script]
recipe = slapos.recipe.template
url = ${create-svn-repo:location}/${create-svn-repo:filename}
output = $${rootdirectory:bin}/create-svn-repository.sh
mode = 0700
trac_admin = ${buildout:bin-directory}
svn_bin = ${subversion-1.9:location}/bin
svn_python = ${subversion-1.9:location}/lib/svn-python
python_lib = ${python2.7:location}/lib
[gitweb-conf]
recipe = slapos.recipe.template
url = ${template-gitweb-conf:location}/${template-gitweb-conf:filename}
output = $${rootdirectory:etc}/gitweb.conf
url-list = $${trac-config:project_url}git http://[$${slap-network-information:global-ipv6}]:8080/git git://[$${slap-network-information:global-ipv6}]
base-directory = $${trac-config:project_dir}/git
[gitweb-cgi]
recipe = slapos.recipe.template
url = ${template-gitweb-cgi:location}/${template-gitweb-cgi:filename}
output = $${rootdirectory:bin}/gitweb.cgi
mode = 700
perl = ${perl:location}/bin/perl
gitweb = ${gitweb:location}/share/gitweb/gitweb.cgi
[git-http-backend-cgi]
recipe = slapos.recipe.template
url = ${template-git-http-backend-cgi:location}/${template-git-http-backend-cgi:filename}
output = $${rootdirectory:bin}/git-http-backend.cgi
mode = 700
githttpbackend = ${git:location}/libexec/git-core/git-http-backend
base-directory = $${trac-config:project_dir}/git
[trac-admin]
recipe = slapos.cookbook:pwgen
file = $${buildout:directory}/.password
pwgen-binary = ${pwgen:location}/bin/pwgen
user = TracAdmin
#---------------------
#to avoid manipulate apache after installation, this part is installed before
#running apache services for the first time
[inittrac]
recipe = slapos.cookbook:trac
site-dir = $${trac-config:project_dir}
site-url = $${trac-config:project_url}
project = $${slap-parameter:project-name}
#Use to install trac additional plugins
plugins-egg-dir = ${trac-plugins-egg:location}
#Usefull for update pythonPath
eggs-dirs =
${buildout:eggs-directory}
${buildout:develop-eggs-directory}
python-lib = ${python2.7:location}/lib
trac-admin = ${buildout:bin-directory}/trac-admin
admin-user = $${trac-admin:user}
admin-password = $${trac-admin:password}
#MySQL informations
mysql-username = $${mariadb-urlparse:username}
mysql-password = $${mariadb-urlparse:password}
mysql-database = $${mariadb-urlparse:path}
mysql-host = $${stunnel:local-host}
mysql-port = $${stunnel:local-port}
#SVN - GIT Project list
svn-project-list = $${slap-parameter:svn-project-list}
git-project-list = $${slap-parameter:git-project-list}
git-binary = ${git:location}/bin/git
#configurations files
trac-ini = $${trac-config:output}
trac-wsgi = $${trac-wsgi:output}
svn-repo-script = $${trac-svnrepo-script:output}
post-revprop-change = $${post-revprop-change-script:output}
trac-svn-hook = $${trac-svn-hook-script:output}
trac-git-hook = $${trac-git-hook-script:output}
file-status = $${buildout:directory}/.status
#Trac User list
htpasswd = ${apache:location}/bin/htpasswd
passwd-file = $${trac-config:project_dir}/.htpasswd
user-list = $${slap-parameter:trac-user-list}
[httpd]
recipe = slapos.cookbook:wrapper
command-line = ${apache:location}/bin/httpd -DFOREGROUND -f "$${httpd-conf:output}"
environment = PYTHONPATH=${subversion-1.9:location}/lib/svn-python:$${inittrac:python_path}
LD_LIBRARY_PATH=${python2.7:location}/lib
wrapper-path = $${basedirectory:services}/httpd
wait-for-files = $${inittrac:file-status}
[gitdaemon]
recipe = slapos.cookbook:wrapper
ip = $${slap-network-information:global-ipv6}
port = 9418
command-line = ${git:location}/bin/git daemon --export-all --listen=$${:ip} --port=$${:port} --interpolated-path=$${inittrac:site-dir}/git/%D
wrapper-path = $${basedirectory:services}/git-daemon
wait-for-files = $${inittrac:file-status}
[logrotate-entry-apache]
<= logrotate
recipe = slapos.cookbook:logrotate.d
name = apache
log = $${httpd-conf:error_log} $${httpd-conf:access_log}
frequency = daily
rotate-num = 30
sharedscripts = true
notifempty = true
create = true
#--------------------------
#-----
#---- Request Console for Trac-administration (cannot use Trac without console admin)
[ca-shellinabox]
<= certificate-authority
recipe = slapos.cookbook:certificate_authority.request
executable = $${shellinabox:wrapper}
wrapper = $${basedirectory:services}/shellinaboxd
key-file = $${shellinabox:key-file}
cert-file = $${shellinabox:cert-file}
[shellinabox]
recipe = slapos.cookbook:shellinabox
ipv6 = $${slap-network-information:global-ipv6}
port = 9000
shell = $${shell:wrapper}
wrapper = $${rootdirectory:bin}/shellinaboxd_raw
shellinabox-binary = ${shellinabox:location}/bin/shellinaboxd
password = $${trac-admin:password}
directory = $${inittrac:site-dir}
login-shell = $${rootdirectory:bin}/login
certificate-directory = $${directory:shellinabox}
cert-file = $${directory:shellinabox}/public.crt
key-file = $${directory:shellinabox}/private.key
[shell-wrapper]
recipe = slapos.cookbook:wrapper
command-line = ${buildout:bin-directory}/trac-admin $${inittrac:site-dir}
environment = PYTHONPATH=${subversion-1.9:location}/lib/svn-python:$${inittrac:python_path}
ENV=$${inittrac:site-dir}
SNV_REPOS=$${inittrac:site-dir}/svn
GIT_REPOS=$${inittrac:site-dir}/git
wrapper-path = $${rootdirectory:bin}/shell_raw
[shell]
recipe = slapos.cookbook:shell
wrapper = $${rootdirectory:bin}/shell
shell = $${shell-wrapper:wrapper-path}
home = $${inittrac:site-dir}
ps1 = "\\w> "
path =
#----------------
#--
#-- Request frontend.
#-- We need to remove dependancy between apache, trac and frontend, because url is needed in
#-- trac configuration file and apache depend on trac.
[request-frontend]
<= slap-connection
recipe = slapos.cookbook:requestoptional
name = Frontend
# XXX We have hardcoded SR URL here.
software-url = http://git.erp5.org/gitweb/slapos.git/blob_plain/HEAD:/software/apache-frontend/software.cfg
slave = true
config = url custom_domain
config-url = http://[$${slap-network-information:global-ipv6}]:8080
return = site_url
config-custom_domain = $${slap-parameter:domain}
#----------------
#--
#-- Publish instance parameters.
[publish-connection-informations]
recipe = slapos.cookbook:publish
backend_url = http://[$${httpd-conf:ip}]:$${httpd-conf:port}/
frontend_url = $${request-frontend:connection-site_url}
git = $${request-frontend:connection-site_url}git/
svn = $${request-frontend:connection-site_url}svn/
admin_user = $${trac-admin:user}
admin_password = $${trac-admin:password}
admin_shell = https://[$${shellinabox:ipv6}]:$${shellinabox:port}/
#----------------
#--
#-- Deploy promises scripts.
[promise]
recipe = slapos.cookbook:check_port_listening
path = $${basedirectory:promises}/apache
hostname = $${httpd-conf:ip}
port = $${httpd-conf:port}
[frontend-promise]
recipe = slapos.cookbook:check_url_available
path = $${basedirectory:promises}/frontend
url = $${request-frontend:connection-site_url}
dash_path = ${dash:location}/bin/dash
curl_path = ${curl:location}/bin/curl
[content-promise]
recipe = slapos.cookbook:check_page_content
path = $${basedirectory:promises}/content
url = $${request-frontend:connection-site_url}
dash_path = ${dash:location}/bin/dash
curl_path = ${curl:location}/bin/curl
match = $${slap-parameter:project-name}
[slap-parameter]
domain =
project-name = project
project-desc = My example project
project-footer = Visit the Trac open source project at<br /><a href="http://trac.edgewall.org/">http://trac.edgewall.org/</a>
admin-email = you.admin@email.com
trac-user-list = {}
svn-project-list = {}
git-project-list = {}
software/trac-svn/instance.cfg
0 → 100644
View file @
20d2c4e5
[buildout]
parts =
switch_softwaretype
eggs-directory = ${buildout:eggs-directory}
develop-eggs-directory = ${buildout:develop-eggs-directory}
offline = true
[switch_softwaretype]
recipe = slapos.cookbook:softwaretype
default = ${instance-trac:output}
mariadb = ${instance-mariadb:output}
\ No newline at end of file
software/trac-svn/software.cfg
0 → 100644
View file @
20d2c4e5
[buildout]
develop =
${:parts-directory}/slapos.cookbook-repository
# ${trac-plugins-egg:location}/accountmanager
parts =
apache-wsgi
slapos-cookbook
gitweb
subversion-1.9
instance-egg
instance
instance-trac
instance-mariadb
template-httpd-conf
tracWsgi
tracIni
trac-svn-hook
trac-git-hook
post-revprop-change
template-gitweb-cgi
template-gitweb-conf
template-git-http-backend-cgi
# trac-plugins-egg
# check-egg
slapos.cookbook-repository
check-recipe
extends =
../../stack/slapos.cfg
../../component/apache/buildout.cfg
../../component/python-2.7/buildout.cfg
../../component/apache-wsgi/buildout.cfg
../../component/logrotate/buildout.cfg
../../component/subversion/buildout.cfg
../../component/gzip/buildout.cfg
../../component/dcron/buildout.cfg
../../component/dash/buildout.cfg
../../component/stunnel/buildout.cfg
../../component/lxml-python/buildout.cfg
../../component/mysql-python/buildout.cfg
../../component/git/buildout.cfg
../../component/pwgen/buildout.cfg
../../component/shellinabox/buildout.cfg
../../component/perl/buildout.cfg
allow-hosts +=
*.edgewall.org
*.edgewall.com
[lxml-python]
python = python2.7
[instance-egg]
recipe = z3c.recipe.scripts
python = python2.7
eggs =
${mysql-python:egg}
slapos.toolbox
collective.recipe.cmd
Genshi
docutils
Pygments
pytz
Trac
[trac-plugins-egg]
recipe = plone.recipe.command
svn = ${subversion-1.9:location}/bin/svn
location = ${buildout:parts-directory}/${:_buildout_section_name_}
#command = ${:svn} co http://trac-hacks.org/svn/simplemultiprojectplugin/trunk/ ${:multipleproject}
command = ${:svn} co http://trac-hacks.org/svn/accountmanagerplugin/0.11 ${:location}/accountmanager
[check-egg]
recipe = plone.recipe.command
stop-on-error = true
update-command = ${:command}
command = grep parts ${buildout:develop-eggs-directory}/accountmanager.egg-link
[instance]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance.cfg
output = ${buildout:directory}/template.cfg
mode = 0644
md5sum = bc6ed91a1862a10af661713aa0691848
[instance-trac]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-trac.cfg
output = ${buildout:directory}/template-trac.cfg
md5sum = 1546a60e086b4d083d58ad4fca6dcca8
mode = 0644
[instance-mariadb]
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/instance-mariadb.cfg
output = ${buildout:directory}/template-mariadb.cfg
md5sum = 4ea69039e41ff45bffe8f2620bdf187c
mode = 0644
[template-download]
recipe = slapos.recipe.download
url = ${:_profile_base_location_}/templates/${:filename}
mode = 0644
location = ${buildout:parts-directory}/${:_buildout_section_name_}
[tracIni]
<= template-download
filename = trac.ini.in
md5sum = 10286b368b9b6eacae2cdd6caf362759
[tracWsgi]
<= template-download
filename = trac.wsgi.in
md5sum = 5226978477d3336f21f0d8684d23a55a
[trac-svn-hook]
<= template-download
filename = trac-svn-hook.in
md5sum = 81a0e2627af1db4c1d601aabc0ebee0a
[trac-git-hook]
<= template-download
filename = trac-git-hook.in
md5sum = 8704e9717bf1223157b3d25de5a8d9d6
[post-revprop-change]
<= template-download
filename = post-revprop-change.in
md5sum = 917deaeda572ca3e98c2baaf15fcdacc
[create-svn-repo]
<= template-download
filename = create-svn-repo.sh.in
md5sum = 3e4d25ce53dcc3729f4bc682e0d2d239
[template-httpd-conf]
<= template-download
filename = apache.in
md5sum = 4f6d1b748c149f32a39c89931e0cd94a
[template-gitweb-cgi]
<= template-download
filename = gitweb.cgi.in
md5sum = 957a7741c7ab60c4bee6c640e0bdd2fb
[template-gitweb-conf]
<= template-download
filename = gitweb.conf.in
md5sum = ace5a69f59c0be7ea7454183a5550537
[template-git-http-backend-cgi]
<= template-download
filename = git-http-backend.cgi.in
md5sum = d6101df47ddd3b04e34e1f0284686b55
# Local development
[slapos.cookbook-repository]
recipe = plone.recipe.command
stop-on-error = true
branch = trac
revision =
location = ${buildout:parts-directory}/${:_buildout_section_name_}
command = "${git:location}/bin/git" clone --branch "${:branch}" --quiet http://git.erp5.org/repos/slapos.git "${:location}" && if [ -n "${:revision}" ]; then cd "${:location}" && "${git:location}/bin/git" reset --quiet --hard "${:revision}" ; fi
update-command = cd "${:location}" && "${git:location}/bin/git" fetch --quiet && if [ -n "${:revision}" ]; then "${git:location}/bin/git" reset --hard "${:revision}"; else "${git:location}/bin/git" reset --quiet --hard @{upstream} ; fi
[check-recipe]
recipe = plone.recipe.command
stop-on-error = true
update-command = ${:command}
command = grep parts ${buildout:develop-eggs-directory}/slapos.cookbook.egg-link
[networkcache]
# signature certificates of the following uploaders.
# Romain Courteaud
# Sebastien Robin
# Kazuhiko Shiozaki
# Cedric de Saint Martin
# Yingjie Xu
# Gabriel Monnerat
# Åukasz Nowak
# Test Agent (Automatic update from tests)
signature-certificate-list =
-----BEGIN CERTIFICATE-----
MIIB4DCCAUkCADANBgkqhkiG9w0BAQsFADA5MQswCQYDVQQGEwJGUjEZMBcGA1UE
CBMQRGVmYXVsdCBQcm92aW5jZTEPM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mKBNHTJE2hFlMB8GA1UdIwQYMBaAFEfjy3OopT2lOksK
mKBNHTJE2hFlMAwGA1UdEwQFMAMBAf8wDQYJKoZIhvcNAQEFBQADgYEAaNRx6YN2
M/p3R8/xS6zvH1EqJ3FFD7XeAQ52WuQnKSREzuw0dsw12ClxjcHiQEFioyTiTtjs
5pW18Ry5Ie7iFK4cQMerZwWPxBodEbAteYlRsI6kePV7Gf735Y1RpuN8qZ2sYL6e
x2IMeSwJ82BpdEI5niXxB+iT0HxhmR+XaMI=
-----END CERTIFICATE-----
[versions]
#Error: Couldn't install: lxml 3.1.2
lxml = 3.1.1
Genshi = 0.7
Jinja2 = 2.6
MySQL-python = 1.2.4
Pygments = 1.6
Trac = 1.0.1
Werkzeug = 0.8.3
apache-libcloud = 0.12.4
async = 0.6.1
buildout-versions = 1.7
collective.recipe.cmd = 0.6
docutils = 0.10
gitdb = 0.5.4
hexagonit.recipe.cmmi = 2.0
inotifyx = 0.2.0
meld3 = 0.6.10
netaddr = 0.7.10
plone.recipe.command = 1.1
pycrypto = 2.6
pytz = 2013b
slapos.recipe.download = 1.0.dev-r4053
slapos.recipe.template = 2.4.2
slapos.toolbox = 0.34.0
smmap = 0.8.2
z3c.recipe.scripts = 1.0.1
# Required by:
# slapos.core==0.35.1
# slapos.toolbox==0.34.0
Flask = 0.9
# Required by:
# slapos.toolbox==0.34.0
GitPython = 0.3.2.RC1
# Required by:
# slapos.toolbox==0.34.0
atomize = 0.1.1
# Required by:
# slapos.toolbox==0.34.0
feedparser = 5.1.3
# Required by:
# slapos.core==0.35.1
netifaces = 0.8
# Required by:
# slapos.toolbox==0.34.0
paramiko = 1.10.1
# Required by:
# slapos.toolbox==0.34.0
psutil = 0.7.0
# Required by:
# slapos.core==0.35.1
pyflakes = 0.7.1
# Required by:
# hexagonit.recipe.download==1.6nxd002
# slapos.cookbook==0.76.1.dev
# slapos.core==0.35.1
# supervisor==3.0b1
# zc.buildout==1.6.0-dev-SlapOS-010
# zope.interface==4.0.5
setuptools = 0.6c12dev-r88846
# Required by:
# slapos.toolbox==0.34.0
slapos.core = 0.35.1
# Required by:
# slapos.core==0.35.1
supervisor = 3.0b1
# Required by:
# slapos.core==0.35.1
unittest2 = 0.5.1
# Required by:
# slapos.toolbox==0.34.0
xml-marshaller = 0.9.7
# Required by:
# slapos.core==0.35.1
zope.interface = 4.0.5
software/trac-svn/templates/apache.in
0 → 100644
View file @
20d2c4e5
# Apache static configuration
# Automatically generated
# Basic server configuration
PidFile "${:pid_file}"
Listen ${:ip}:${:port}
ServerAdmin someone@email
TypesConfig conf/mime.types
AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz
# Log configuration
ErrorLog "${:error_log}"
LogLevel warn
LogFormat "%h %{REMOTE_USER}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
LogFormat "%h %{REMOTE_USER}i %l %u %t \"%r\" %>s %b" common
CustomLog "${:access_log}" common
ScriptSock "${:cgid-sock}"
SetEnv REMOTE_USER=$REDIRECT_REMOTE_USER
# Directory protection
<Directory />
Options FollowSymLinks
AllowOverride None
Require all denied
</Directory>
WSGIScriptAlias / ${:wsgi_location}/trac.wsgi
<Directory ${:wsgi_location}>
WSGIApplicationGroup %{GLOBAL}
AllowOverride All
Require all granted
</Directory>
<Location /login>
AuthType Basic
AuthName "Trac Administrator Access"
AuthUserFile ${:document_root}/.htpasswd
Require valid-user
</Location>
<Location /svn>
ErrorDocument 404 default
DAV svn
SVNParentPath ${:document_root}/svn/
AuthType Basic
AuthName "SVN Repository Access"
AuthUserFile ${:document_root}/.htpasswd
SVNAdvertiseV2Protocol Off
<LimitExcept GET PROPFIND OPTIONS REPORT>
Require valid-user
</LimitExcept>
</Location>
Alias "/static/" "${:gitweb-static-dir}"
<Directory "${:gitweb-static-dir}">
Options FollowSymLinks
Require all granted
</Directory>
# This is Static Accelerated git pull
AliasMatch "^/git/(.*/objects/[0-9a-f]{2}/[0-9a-f]{38})$" "${:document_root}/git/$1"
AliasMatch "^/git/(.*/objects/pack/pack-[0-9a-f]{40}.(pack|idx))$" "${:document_root}/git/$1"
# When it can't be statically delivered, we rely on git-http-backend
ScriptAliasMatch \
"(?x)^/git/(.*/(HEAD | \
info/refs | \
objects/(info/[^/]+ | \
[0-9a-f]{2}/[0-9a-f]{38} | \
pack/pack-[0-9a-f]{40}\.(pack|idx)) | \
git-(upload|receive)-pack))$" \
"${:git-http-backend}/$1"
# Everything else is gitweb interface
ScriptAlias "/git" "${:gitweb-script}"
RewriteEngine On
RewriteCond %{QUERY_STRING} service=git-receive-pack
RewriteRule ^/git/.*/info/refs$ - [E=git_receive_pack:1]
<Location /git>
Order deny,allow
Deny from env=git_receive_pack
AuthType Basic
AuthName "Git Push Access"
AuthBasicProvider file
AuthUserFile ${:document_root}/.htpasswd
Require valid-user
Satisfy any
</Location>
<LocationMatch "^/git/.*/git-receive-pack$">
AuthType Basic
AuthName "Git Push Access"
AuthBasicProvider file
AuthUserFile ${:document_root}/.htpasswd
Require valid-user
SetEnv REMOTE_USER $REDIRECT_REMOTE_USER
</LocationMatch>
# List of modules
LoadModule unixd_module modules/mod_unixd.so
LoadModule access_compat_module modules/mod_access_compat.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule version_module modules/mod_version.so
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule mime_module modules/mod_mime.so
LoadModule cgid_module modules/mod_cgid.so
LoadModule env_module modules/mod_env.so
LoadModule dav_module modules/mod_dav.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule headers_module modules/mod_headers.so
LoadModule dir_module modules/mod_dir.so
LoadModule alias_module modules/mod_alias.so
LoadModule wsgi_module modules/mod_wsgi.so
LoadModule dav_svn_module modules/mod_dav_svn.so
LoadModule authz_svn_module modules/mod_authz_svn.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule authn_core_module modules/mod_authn_core.so
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authz_core_module modules/mod_authz_core.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule autoindex_module modules/mod_autoindex.so
\ No newline at end of file
software/trac-svn/templates/create-svn-repo.sh.in
0 → 100644
View file @
20d2c4e5
#!/bin/sh
export
PATH
=
${
:trac_admin
}
:
${
:svn_bin
}
:
$PATH
export
PYTHONPATH
=
${
:svn_python
}
:
$PYTHONPATH
export
LD_LIBRARY_PATH
=
${
:python_lib
}
:
$LD_LIBRARY_PATH
ENV
=
"
$1
"
REPO
=
"
$2
"
REALM
=
"
$3
"
if
[
-z
"
$ENV
"
-o
-z
"
$REPO
"
]
;
then
echo
"Usage:
$0
ENV REPO"
exit
2
fi
RPATH
=
"
$ENV
/svn/
$REPO
"
PASSWD
=
"
$ENV
/svnpasswd"
svnadmin create
$RPATH
trac-admin
$ENV
repository add
$REPO
$RPATH
svn
trac-admin
$ENV
repository resync
$REPO
echo
"[general]
anon-access = read
auth-access = write
password-db =
$PASSWD
realm =
$REALM
"
>
$RPATH
/conf/svnserve.conf
software/trac-svn/templates/git-http-backend.cgi.in
0 → 100644
View file @
20d2c4e5
#!/bin/sh
## This is a very dirty hack
export
PATH_INFO
=
"
$$
{REDIRECT_URL:-
$PATH_INFO
}"
GIT_PROJECT_ROOT
=
'${:base-directory}'
GIT_HTTP_EXPORT_ALL
=
exec
'${:githttpbackend}'
$@
software/trac-svn/templates/gitweb.cgi.in
0 → 100644
View file @
20d2c4e5
#!/bin/sh
GITWEB_CONFIG
=
'${gitweb-conf:output}'
exec
'${:perl}'
'${:gitweb}'
$@
\ No newline at end of file
software/trac-svn/templates/gitweb.conf.in
0 → 100644
View file @
20d2c4e5
$projectroot = '${:base-directory}';
$site_name = '${slap-parameter:project-name}';
our @git_base_url_list = qw(${:url-list});
# Beautiful URLs
$feature{'pathinfo'}{'default'} = [1];
$feature{'blame'}{'default'} = [1];
software/trac-svn/templates/post-revprop-change.in
0 → 100644
View file @
20d2c4e5
#!/bin/sh
if
[
"
$PROPNAME
"
=
"svn:log"
-o
"
$PROPNAME
"
=
"svn:author"
]
;
then
${
:trac_svn_hook
}
$REPOS
$REV
$USER
$PROPNAME
fi
\ No newline at end of file
software/trac-svn/templates/trac-git-hook.in
0 → 100644
View file @
20d2c4e5
#!/bin/sh
REV
=
$(
${
:git_bin
}
rev-parse HEAD
)
${
:trac_admin
}
${
:trac_env
}
added
"
$1
"
$REV
\ No newline at end of file
software/trac-svn/templates/trac-svn-hook.in
0 → 100644
View file @
20d2c4e5
#!/bin/sh
export
TRAC_ENV
=
${
:trac_env
}
export
PATH
=
${
:trac_admin
}
:
${
:python_bin
}
:
$PATH
export
LD_LIBRARY_PATH
=
${
:python_lib
}
:
$LD_LIBRARY_PATH
export
PYTHONPATH
=
${
:svn_python
}
:
$PYTHONPATH
REPOS
=
"
$1
"
REV
=
"
$2
"
USER
=
"
$3
"
PROPNAME
=
"
$4
"
# -- Foolproofing
if
[
-z
"
$REPOS
"
-o
-z
"
$REV
"
]
;
then
echo
"Usage:
$0
REPOS REV"
exit
2
fi
if
!
python
-V
2>/dev/null
;
then
echo
"python is not in the PATH (
$PATH
), check PATH and LD_LIBRARY_PATH."
exit
2
fi
if
[
-z
"
$TRAC_ENV
"
]
;
then
echo
"TRAC_ENV is not set."
exit
2
fi
# -- Feedback
echo
"----"
if
[
-z
"
$USER
"
-a
-z
"
$PROPNAME
"
]
;
then
EVENT
=
"added"
echo
"Changeset
$REV
was added in
$REPOS
"
else
EVENT
=
"modified"
echo
"Changeset
$REV
was modified by
$USER
in
$REPOS
"
fi
# -- Call "trac-admin ... changeset ... $$REPOS $$REV" for each Trac environment
ifs
=
$IFS
IFS
=
:
if
[
-n
"
$BASH_VERSION
"
]
;
then
# we can use Bash syntax
if
[[
$$
{
BASH_VERSINFO[5]
}
=
*
cygwin
]]
;
then
IFS
=
";"
fi
fi
for
env
in
$TRAC_ENV
;
do
if
[
-r
"
$env
/VERSION"
]
;
then
log
=
$env
/log/svn-hooks-
`
basename
$REPOS
`
.log
nohup
sh
<<
EOF
>>
$log
2>&1 &
echo "Changeset
$REV
$EVENT
"
trac-admin
$env
changeset
$EVENT
$REPOS
$REV
&&
\
echo "OK" || echo "FAILED: see the Trac log"
EOF
else
echo
"
$env
doesn't seem to be a Trac environment, skipping..."
fi
done
IFS
=
$ifs
software/trac-svn/templates/trac.ini.in
0 → 100644
View file @
20d2c4e5
# -*- coding: utf-8 -*-
[attachment]
max_size = 262144
max_zip_size = 2097152
render_unsafe_content = false
[browser]
color_scale = True
downloadable_paths = /trunk, /branches/*, /tags/*
hide_properties = svk:merge
intermediate_color =
intermediate_point =
newest_color = (255, 136, 136)
oldest_color = (136, 136, 255)
oneliner_properties = trac:summary
render_unsafe_content = false
wiki_properties = trac:description
[changeset]
max_diff_bytes = 10000000
max_diff_files = 0
wiki_format_messages = true
[header_logo]
alt = (please configure the [header_logo] section in trac.ini)
height = -1
link =
src = site/your_project_logo.png
width = -1
[git]
cached_repository = false
git_bin = ${:git_bin}
git_fs_encoding = utf-8
persistent_cache = false
projects_base = ${:git_project_base}
projects_list = ${:git_project_list}
projects_url = ${:git_url}
shortrev_len = 7
trac_user_rlookup = false
use_committer_id = true
use_committer_time = true
wikishortrev_len = 40
[svn]
branches = trunk, branches/*
tags = tags/*
[components]
webadmin.* = enabled
tracopt.versioncontrol.svn.* = enabled
tracopt.versioncontrol.git.* = enabled
tracopt.ticket.commit_updater.* = enabled
[inherit]
htdocs_dir =
plugins_dir = ${:trac_plugins}
templates_dir =
[logging]
log_file = trac.log
# log_format = <inherited>
log_level = DEBUG
log_type = none
[milestone]
stats_provider = DefaultTicketGroupStatsProvider
[mimeviewer]
max_preview_size = 262144
mime_map = text/x-dylan:dylan, text/x-idl:ice, text/x-ada:ads:adb
mime_map_patterns = text/plain:README|INSTALL|COPYING.*
pygments_default_style = trac
pygments_modes =
tab_width = 8
treat_as_binary = application/octet-stream, application/pdf, application/postscript, application/msword,application/rtf,
[notification]
admit_domains =
always_notify_owner = false
always_notify_reporter = false
always_notify_updater = true
ambiguous_char_width = single
batch_subject_template = $prefix Batch modify: $tickets_descr
email_sender = SmtpEmailSender
ignore_domains =
mime_encoding = none
sendmail_path = sendmail
smtp_always_bcc =
smtp_always_cc =
smtp_default_domain =
smtp_enabled = false
smtp_from = trac@localhost
smtp_from_author = false
smtp_from_name =
smtp_password =
smtp_port = 25
smtp_replyto = trac@localhost
smtp_server = localhost
smtp_subject_prefix = __default__
smtp_user =
ticket_subject_template = $prefix #$ticket.id: $summary
use_public_cc = false
use_short_addr = false
use_tls = false
[project]
admin = ${:admin_email}
admin_trac_url = .
descr = ${:project_description}
footer = ${:project_footer}
icon = common/trac.ico
name = ${:project_name}
url = ${:project_url}
[query]
default_anonymous_query = status!=closed&cc~=$USER
default_query = status!=closed&owner=$USER
items_per_page = 100
ticketlink_query = ?status=!closed
[report]
items_per_page = 100
items_per_page_rss = 0
[revisionlog]
default_log_limit = 100
graph_colors = ['#cc0', '#0c0', '#0cc', '#00c', '#c0c', '#c00']
[roadmap]
stats_provider = DefaultTicketGroupStatsProvider
[search]
# default_disabled_filters = <inherited>
min_query_length = 3
[sqlite]
# extensions = <inherited>
[ticket]
default_cc =
default_component =
default_description =
default_keywords =
default_milestone =
default_owner = < default >
default_priority = major
default_resolution = fixed
default_severity =
default_summary =
default_type = defect
default_version =
max_comment_size = 262144
max_description_size = 262144
preserve_newlines = default
restrict_owner = false
workflow = ConfigurableTicketWorkflow
[ticket-workflow]
accept = new,assigned,accepted,reopened -> accepted
accept.operations = set_owner_to_self
accept.permissions = TICKET_MODIFY
leave = * -> *
leave.default = 1
leave.operations = leave_status
reassign = new,assigned,accepted,reopened -> assigned
reassign.operations = set_owner
reassign.permissions = TICKET_MODIFY
reopen = closed -> reopened
reopen.operations = del_resolution
reopen.permissions = TICKET_CREATE
resolve = new,assigned,accepted,reopened -> closed
resolve.operations = set_resolution
resolve.permissions = TICKET_MODIFY
[ticket-custom]
project = ${:project_name}
project.label = Project
project.value =
[timeline]
abbreviated_messages = True
changeset_collapse_events = false
changeset_long_messages = false
changeset_show_files = 0
default_daysback = 30
max_daysback = 90
newticket_formatter = oneliner
ticket_show_details = false
[trac]
auth_cookie_lifetime = 0
auth_cookie_path =
authz_file =
authz_module_name =
auto_preview_timeout = 2.0
auto_reload = False
backup_dir = db
base_url = ${:project_url}
check_auth_ip = false
database = mysql://${:mysql_username}:${:mysql_password}@${:mysql_host}:${:mysql_port}/${:mysql_database}
debug_sql = False
default_charset = utf-8
default_dateinfo_format = relative
genshi_cache_size = 128
htdocs_location =
ignore_auth_case = false
jquery_location =
jquery_ui_location =
jquery_ui_theme_location =
mainnav = wiki, timeline, roadmap, browser, tickets, newticket, search
metanav = login, logout, prefs, help, about
mysqldump_path = mysqldump
never_obfuscate_mailto = false
permission_policies = DefaultPermissionPolicy, LegacyAttachmentPolicy
permission_store = DefaultPermissionStore
pg_dump_path = pg_dump
repository_dir =
repository_sync_per_request = (default)
repository_type = svn
resizable_textareas = true
secure_cookies = False
show_email_addresses = false
show_ip_addresses = false
timeout = 20
use_base_url_for_redirect = False
[versioncontrol]
allowed_repository_dir_prefixes =
[wiki]
ignore_missing_pages = false
max_size = 262144
render_unsafe_content = false
safe_schemes = cvs, file, ftp, git, irc, http, https, news, sftp, smb, ssh, svn, svn+ssh
split_page_names = false
software/trac-svn/templates/trac.wsgi.in
0 → 100644
View file @
20d2c4e5
#!${:python_bin}
# -*- coding: utf-8 -*-
import os
def application(environ, start_request):
if not 'trac.env_parent_dir' in environ:
environ.setdefault('trac.env_path', '${:trac_env}')
if 'PYTHON_EGG_CACHE' in environ:
os.environ['PYTHON_EGG_CACHE'] = environ['PYTHON_EGG_CACHE']
elif 'trac.env_path' in environ:
os.environ['PYTHON_EGG_CACHE'] = \
os.path.join(environ['trac.env_path'], '.egg-cache')
elif 'trac.env_parent_dir' in environ:
os.environ['PYTHON_EGG_CACHE'] = \
os.path.join(environ['trac.env_parent_dir'], '.egg-cache')
from trac.web.main import dispatch_request
return dispatch_request(environ, start_request)
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment