1 Initialising a dak database schema
2 ==================================
4 The following packages are needed:
5 * postgresql-9.0 postgresql-client-9.0 postgresql-plperl-9.0 postgresql-plpython-9.0 postgresql-9.0-debversion
7 (the schema assumes at least postgresql 9.0; ftpmaster in Debian currently uses
8 the squeeze postgresql 9.0 backport)
10 The following roles are assumed to exist:
11 * dak: database superuser: needs to be an actual user
12 * ftpmaster: role which should be given to archive administrators
13 * ftpteam: people who can do NEW processing, overrides, removals, etc
14 * ftptrainee: people who can add notes to packages in NEW
16 For the purposes of this document, we'll be working in /srv/dak
18 Set up the dak user on both the system and in postgres:
20 # sudo addgroup ftpmaster
21 # sudo addgroup dak ftpmaster
22 # sudo -u postgres createuser -s dak
24 Set up the dak directory:
26 # sudo chown dak:ftpmaster /srv/dak
27 # sudo chmod 2775 /srv/dak
32 Create the additional roles:
33 # createuser -S -R -D ftpmaster
34 # createuser -S -R -D ftpteam
35 # createuser -S -R -D ftptrainee
37 Create an empty database with SQL_ASCII encoding:
38 # createdb -T template0 -E SQL_ASCII -O dak projectb
41 # psql -f current_schema.sql -d projectb
43 Set up some core data in projectb to get started (read the init_vars file if
44 you wish to customise various aspects):
47 Create a minimal dak.conf
49 # cp dak-minimal.conf /etc/dak/dak.conf
51 Add some architectures you care about:
52 # dak admin architecture add i386 "Intel x86 port"
53 # dak admin architecture add amd64 "AMD64 port"
55 Add a suite (origin=, label= and codename= are optional)
56 # dak admin suite add-all-arches unstable x.y.z origin=MyDistro label=Master codename=sid