git-update.py: Check for mandatory fields
[aur.git] / INSTALL
blob7b90ffd2b35476f4d2377143d85682610a7fce3e
1 Setup on Arch Linux
2 ===================
4 1) Clone the AUR project:
6    $ cd /srv/http/
7    $ git clone git://projects.archlinux.org/aur.git
9 2) Setup a web server with PHP and MySQL. Configure the web server to redirect
10    all URLs to /index.php/foo/bar/. The following block can be used with nginx:
12     location ~ .* {
13         rewrite ^/(.*)$ /index.php/$1 last;
14     }
16 3) Copy conf/config.proto to conf/config and adjust the configuration.
18 4) Create a new MySQL database and a user and import the AUR SQL schema:
20    $ mysql -uaur -p AUR </srv/http/aur/schema/aur-schema.sql
22 5) Generate templates for new Git repositories:
24    $ /srv/http/aur/scripts/git-integration/gen-templates.py
26 6) Clone the OpenSSH project, apply the AUR sshd patch and run `make`:
28    $ cd /srv/http/aur/
29    $ git clone git://anongit.mindrot.org/openssh.git
30    $ cd openssh
31    $ git checkout V_6_7_P1
32    $ git am ../scripts/git-integration/0001-Patch-sshd-for-the-AUR.patch
33    $ autoreconf
34    $ ./configure
35    $ make
37 7) Create and edit the sshd configuration:
39    $ cd /srv/http/aur/
40    $ umask 077
41    $ mkdir .ssh/
42    $ ssh-keygen -f .ssh/ssh_host_rsa_key -N '' -t rsa
43    $ cp scripts/git-integration/sshd_config .ssh/
45 8) Create a new user and change ownership of the .ssh directory:
47    # useradd -U -d /srv/http/aur -c 'AUR user' aur
48    # chown aur:aur /srv/http/aur/.ssh/
50 9) Add, enable and start systemd unit files for the new sshd:
52    # cp /srv/http/aur/conf/aur-sshd.socket /etc/systemd/system/
53    # cp /srv/http/aur/conf/aur-sshd@.service /etc/systemd/system/
54    # systemctl enable aur-sshd.socket
55    # systemctl start aur-sshd.socket