diff options
author | Caleb Maclennan | 2020-02-28 10:09:19 +0300 |
---|---|---|
committer | Caleb Maclennan | 2020-02-28 10:09:19 +0300 |
commit | 93274b3fc09ae1406fe1c15c29dd0b9501874340 (patch) | |
tree | 981ab334a8e2ede89353ceef1c8c26f25ddfc690 | |
parent | 48a7fc0fea17bf1b3456d6acd6411fdb2b5f5768 (diff) | |
download | aur-93274b3fc09ae1406fe1c15c29dd0b9501874340.tar.gz |
Add install and upgrade instructions
-rw-r--r-- | .SRCINFO | 4 | ||||
-rw-r--r-- | PKGBUILD | 4 | ||||
-rw-r--r-- | pagure.install | 39 |
3 files changed, 45 insertions, 2 deletions
@@ -1,10 +1,12 @@ pkgbase = pagure pkgdesc = A git-centered forge based on python using pygit2 pkgver = 5.8.1 - pkgrel = 0.6 + pkgrel = 0.8 url = https://pagure.io/pagure + install = pagure.install arch = any license = GPL2 + checkdepends = python-tox makedepends = python-setuptools depends = git depends = gitolite @@ -6,7 +6,7 @@ pkgname=pagure pkgver=5.8.1 -pkgrel=0.7 +pkgrel=0.8 pkgdesc="A git-centered forge based on python using pygit2" arch=("any") url="https://pagure.io/$pkgname" @@ -56,6 +56,7 @@ optdepends=('mariadb: MariaDB backend' 'python-pymysql: Python driver for MariaDB') source=("https://releases.pagure.org/$pkgname/$pkgname-$pkgver.tar.gz" "https://src.fedoraproject.org/rpms/pagure/raw/master/f/0501-Revert-Add-a-upper-limit-to-sqlalchemy.patch") +install="$pkgname.install" sha256sums=('5e150bad0a3f932d265cb59d46c8b6a532be0f757aab695a8c37df3f5f4db687' 'c1da9e6ae2255f7896920ecb261f18c59f8ad6ba5726a8484f6287ae3962c854') @@ -78,4 +79,5 @@ package() { cd "$pkgname-$pkgver" python setup.py install --root="$pkgdir" --optimize=1 --skip-build install -Dm644 -t "$pkgdir/usr/share/doc/$pkgname/" {README,UPGRADING}.rst + ls -al } diff --git a/pagure.install b/pagure.install new file mode 100644 index 000000000000..2a9e2abd74e6 --- /dev/null +++ b/pagure.install @@ -0,0 +1,39 @@ +post_install() { + cat <<- EOF + Either MariaDB or PostgreSQL must be configured and running. + To setup using PostreSQL, use: + + \$ sudo -u postgres psql + CREATE DATABASE pagure; + CREATE USER pagure; + ALTER USER pagure WITH ENCRYPTED PASSWORD '--PagureDBUserPW--'; + GRANT ALL PRIVILEGES ON DATABASE pagure to pagure; + GRANT ALL PRIVILEGES ON ALL tables IN SCHEMA public TO pagure; + GRANT ALL PRIVILEGES ON ALL sequences IN SCHEMA public TO pagure; + \\q + + Te setup using MariaDB use: + + \$ sudo mysql -u root -p + mysql> create database pagure; + mysql> grant all privileges on pagure.* to pagure identified by '--PagureDBUserPW--'; + mysql> flush privileges; + mysql> exit + + Configure Pagure is /etc/pagure/pagure.cfg and /etc/pagure/alembic.ini + + Once configured with the correct backend, populate the database: + + python /usr/share/pagure/pagure_createdb.py -c /etc/pagure/pagure.cfg -i /etc/pagure/alembic.ini + EOF +} + +post_upgrade() { + cat <<- EOF + Update Pagure database format using: + + \$ python /usr/share/pagure/pagure_createdb.py -c /etc/pagure/pagure.cfg + EOF +} + +# vim : ts=4 sw=4 noet |