mirror of
https://github.com/moparisthebest/arch-ppa
synced 2024-11-21 08:15:01 -05:00
Add movim-git
This commit is contained in:
parent
fa2fcbaff0
commit
6928fc75af
81
src/movim-git/PKGBUILD
Normal file
81
src/movim-git/PKGBUILD
Normal file
@ -0,0 +1,81 @@
|
||||
# Maintainer: Guillaume Friloux <guillaume@friloux.me>
|
||||
# Co-Maintainer: Maxime "pep" Buquet <archlinux@bouah.net>
|
||||
|
||||
_pkgbase='movim'
|
||||
pkgname=movim-git
|
||||
pkgver=r6116.6937c0c9
|
||||
pkgrel=1
|
||||
pkgdesc="Movim is a decentralized social network, written in PHP and HTML5 and based on the XMPP standard protocol."
|
||||
arch=('any')
|
||||
url='https://movim.eu'
|
||||
license=('AGPL3')
|
||||
provides=('movim')
|
||||
conflicts=('movim')
|
||||
depends=('php-gd' 'php-imagick' 'php-zmq')
|
||||
optdepends=('postgresql: to use the postgresql database backend'
|
||||
'php-pgsql: php bindings for postgresql'
|
||||
'mariadb: to use the mysql database backend'
|
||||
'nginx: reverse proxy'
|
||||
'apache: reverse proxy'
|
||||
'php-fpm: PHP FactCGI process manager')
|
||||
makedepends=('git' 'composer')
|
||||
source=("$_pkgbase::git+https://github.com/movim/movim"
|
||||
movim.env
|
||||
movim.service)
|
||||
install=movim.install
|
||||
sha256sums=('SKIP'
|
||||
'5dfff91dd4a54f3d3713530e204370a96d37898b670a61123d8cad42f92da306'
|
||||
'793b85ca2080d92d9663af1750d0be9d1cbd20de9c828cb0ce0cc91ad5510f11')
|
||||
backup=("etc/webapps/$_pkgbase/db.inc.php"
|
||||
"etc/default/movim")
|
||||
|
||||
pkgver() {
|
||||
cd $srcdir/$_pkgbase
|
||||
echo "r$(git rev-list --count HEAD).$(git rev-parse --short HEAD)"
|
||||
}
|
||||
|
||||
build() {
|
||||
cd $srcdir/$_pkgbase
|
||||
XDG_CACHE_HOME="$srcdir/cache" composer install \
|
||||
--no-interaction --no-dev --no-suggest
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$srcdir/$_pkgbase"
|
||||
|
||||
install -m755 -d "$pkgdir/usr/share/webapps/$_pkgbase"
|
||||
|
||||
# Cache
|
||||
install -m750 -d "$pkgdir/var/cache/webapps/$_pkgbase/cache"\
|
||||
"$pkgdir/var/cache/webapps/$_pkgbase/users"
|
||||
chown -R root:http "$pkgdir/var/cache/webapps/$_pkgbase"
|
||||
chmod -R u+rwX,g+rwX,o-rwx "$pkgdir/var/cache/webapps/$_pkgbase"
|
||||
# XXX: Symlinks created post_upgrade. Waiting for upstream to fix
|
||||
# https://github.com/movim/movim/issues/509.
|
||||
|
||||
cp -r app lib locales src themes vendor "$pkgdir/usr/share/webapps/$_pkgbase"
|
||||
install -Dm644 VERSION CHANGELOG.md INSTALL.md README.md index.php \
|
||||
linker.php manifest.webapp "$pkgdir/usr/share/webapps/$_pkgbase"
|
||||
install -Dm755 daemon.php mud.php "$pkgdir/usr/share/webapps/$_pkgbase"
|
||||
|
||||
# Configuration file
|
||||
install -m750 -d "$pkgdir/etc/webapps/$_pkgbase"
|
||||
install -Dm750 config/db.example.inc.php "$pkgdir/etc/webapps/$_pkgbase/db.inc.php"
|
||||
chown -R root:http "$pkgdir/etc/webapps/$_pkgbase"
|
||||
chmod -R u+rwX,g+rwX,o-rwx "$pkgdir/etc/webapps/$_pkgbase"
|
||||
ln -s "/etc/webapps/$_pkgbase" "$pkgdir/usr/share/webapps/$_pkgbase/config"
|
||||
|
||||
# Log files
|
||||
install -m770 -d "$pkgdir/var/log/webapps/$_pkgbase"
|
||||
chown -R root:http "$pkgdir/var/log/webapps/$_pkgbase"
|
||||
ln -s "/var/log/webapps/$_pkgbase" "$pkgdir/usr/share/webapps/$_pkgbase/log"
|
||||
|
||||
# Systemd unit file
|
||||
install -m755 -d "$pkgdir/etc/default"
|
||||
install -g http -Dm640 "$srcdir/movim.env" "$pkgdir/etc/default/$_pkgbase"
|
||||
install -Dm644 "$srcdir/movim.service" "$pkgdir/usr/lib/systemd/system/movim.service"
|
||||
|
||||
# Easy access to mud.php
|
||||
install -d "$pkgdir/usr/bin"
|
||||
ln -s "/usr/share/webapps/$_pkgbase/mud.php" "$pkgdir/usr/bin/mud"
|
||||
}
|
3
src/movim-git/movim.env
Normal file
3
src/movim-git/movim.env
Normal file
@ -0,0 +1,3 @@
|
||||
MOVIM_URL=https://pod.example.org
|
||||
MOVIM_PORT=8080
|
||||
MOVIM_INTERFACE=[::1]
|
32
src/movim-git/movim.install
Normal file
32
src/movim-git/movim.install
Normal file
@ -0,0 +1,32 @@
|
||||
pre_upgrade() {
|
||||
if [ -d /usr/share/webapps/movim ] && [ ! -L /usr/share/webapps/movim/cache ]; then
|
||||
echo 'The "cache" and "users" folders in /usr/share/webapps/movim are'
|
||||
echo 'being moved to /var/cache/webapps/movim.'
|
||||
|
||||
install -m755 -d /var/cache/webapps/movim
|
||||
mv /usr/share/webapps/movim/{cache,users} /var/cache/webapps/movim/
|
||||
chmod -R u+rwX,g+rwX,o-rwx /var/cache/webapps/movim
|
||||
chown -R root:http /var/cache/webapps/movim
|
||||
fi
|
||||
}
|
||||
|
||||
post_install() {
|
||||
echo 'Post-installation tutorial'
|
||||
echo 'https://github.com/movim/movim/wiki/Install-Movim#2-database-configuration'
|
||||
echo
|
||||
echo 'You should also read'
|
||||
echo 'https://github.com/movim/movim/wiki/Install-Movim#general-behaviour'
|
||||
echo
|
||||
echo 'To complete the setup, please install a database and configure a reverse proxy.'
|
||||
echo 'Don’t forget to adapt /etc/webapps/movim/db.inc.php and /etc/default/movim'
|
||||
echo 'to your server settings'
|
||||
echo 'Once everything is setup, use `systemctl start movim` to start the daemon'
|
||||
}
|
||||
|
||||
post_upgrade() {
|
||||
# XXX: Waiting for upstream to fix https://github.com/movim/movim/issues/509
|
||||
ln -sf /var/cache/webapps/movim/cache /usr/share/webapps/movim
|
||||
ln -sf /var/cache/webapps/movim/users /usr/share/webapps/movim
|
||||
|
||||
post_install $1
|
||||
}
|
14
src/movim-git/movim.service
Normal file
14
src/movim-git/movim.service
Normal file
@ -0,0 +1,14 @@
|
||||
[Unit]
|
||||
Description=Movim Daemon
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Group=http
|
||||
WorkingDirectory=/usr/share/webapps/movim
|
||||
EnvironmentFile=/etc/default/movim
|
||||
ExecStartPre=/usr/bin/php mud.php db --set
|
||||
ExecStart=/usr/bin/php daemon.php start --url=${MOVIM_URL} --port=${MOVIM_PORT} --interface=${MOVIM_INTERFACE}
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
5
src/php-imagick/.gitignore
vendored
Normal file
5
src/php-imagick/.gitignore
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
/imagick-*.tgz
|
||||
/php-imagick-*.pkg.tar.xz
|
||||
/php-imagick-*.src.tar.gz
|
||||
/pkg/
|
||||
/src/
|
10
src/php-imagick/Dockerfile
Normal file
10
src/php-imagick/Dockerfile
Normal file
@ -0,0 +1,10 @@
|
||||
FROM nubs/arch-build
|
||||
|
||||
MAINTAINER Spencer Rinehart <anubis@overthemonkey.com>
|
||||
|
||||
USER root
|
||||
|
||||
RUN pacman --sync --refresh --noconfirm --noprogressbar --quiet
|
||||
RUN pacman --sync --noconfirm --noprogressbar --quiet php imagemagick
|
||||
|
||||
USER build
|
21
src/php-imagick/LICENSE
Normal file
21
src/php-imagick/LICENSE
Normal file
@ -0,0 +1,21 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2014-2016 Spencer Rinehart
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
31
src/php-imagick/PKGBUILD
Normal file
31
src/php-imagick/PKGBUILD
Normal file
@ -0,0 +1,31 @@
|
||||
# Contributor: Spencer Rinehart <anubis@overthemonkey.com>
|
||||
|
||||
pkgname=php-imagick
|
||||
_extname=imagick
|
||||
pkgver=3.4.3
|
||||
pkgrel=3
|
||||
pkgdesc="PHP extension for IMagick"
|
||||
arch=('i686' 'x86_64' 'armv7h')
|
||||
url="https://pecl.php.net/package/${_extname}"
|
||||
license=('PHP')
|
||||
depends=('php>=5.4.0' 'imagemagick>=6.5.3')
|
||||
backup=("etc/php/conf.d/${_extname}.ini")
|
||||
install="php-${_extname}.install"
|
||||
source=("https://pecl.php.net/get/${_extname}-${pkgver}.tgz")
|
||||
md5sums=('d0ee25c007cd2a28cefccc0b9ee63a28')
|
||||
|
||||
build() {
|
||||
cd "${_extname}-${pkgver}"
|
||||
|
||||
phpize
|
||||
./configure --prefix=/usr
|
||||
make
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "${_extname}-${pkgver}"
|
||||
|
||||
make INSTALL_ROOT="${pkgdir}" install
|
||||
echo "extension=${_extname}.so" > "${_extname}.ini"
|
||||
install -D -m644 "${_extname}.ini" "${pkgdir}/etc/php/conf.d/${_extname}.ini"
|
||||
}
|
32
src/php-imagick/README.md
Normal file
32
src/php-imagick/README.md
Normal file
@ -0,0 +1,32 @@
|
||||
# php-imagick-aur
|
||||
An [AUR] package build for PHP's [imagick] extension.
|
||||
|
||||
## Building
|
||||
You can of course build this package using [makepkg], but the recommended way
|
||||
of building this package is using [Docker]. This can be done like so:
|
||||
|
||||
```bash
|
||||
docker build --tag php-imagick-aur .
|
||||
docker run --rm --volume "$(pwd):/package" php-imagick-aur
|
||||
```
|
||||
|
||||
Alternatively, using [Docker Compose]:
|
||||
|
||||
```bash
|
||||
docker-compose run build
|
||||
```
|
||||
|
||||
This will start create a docker image tagged as php-imagick-aur and build the
|
||||
package inside the container. As a result you should get the built package in
|
||||
your current directory.
|
||||
|
||||
## License
|
||||
php-imagick-aur is licensed under the MIT license. See [LICENSE] for the full
|
||||
license text.
|
||||
|
||||
[AUR]: https://aur.archlinux.org/
|
||||
[imagick]: https://pecl.php.net/package/imagick
|
||||
[makepkg]: https://wiki.archlinux.org/index.php/Makepkg
|
||||
[Docker]: https://www.docker.com/
|
||||
[Docker Compose]: https://docs.docker.com/compose/
|
||||
[LICENSE]: https://github.com/nubs/php-imagick-aur/blob/master/LICENSE
|
4
src/php-imagick/docker-compose.yml
Normal file
4
src/php-imagick/docker-compose.yml
Normal file
@ -0,0 +1,4 @@
|
||||
build:
|
||||
build: .
|
||||
volumes:
|
||||
- ".:/package"
|
13
src/php-imagick/php-imagick.install
Normal file
13
src/php-imagick/php-imagick.install
Normal file
@ -0,0 +1,13 @@
|
||||
post_install() {
|
||||
echo '
|
||||
==> PHP extension
|
||||
|
||||
A config file was stored under /etc/php/conf.d/ with the extension enabled.
|
||||
'
|
||||
}
|
||||
|
||||
post_upgrade() {
|
||||
post_install $1
|
||||
}
|
||||
|
||||
# vim:set ts=2 sw=2 et:
|
41
src/php-zmq/PKGBUILD
Normal file
41
src/php-zmq/PKGBUILD
Normal file
@ -0,0 +1,41 @@
|
||||
# Maintainer: wolftankk <wolftankk@gmail.com>
|
||||
pkgname=php-zmq
|
||||
pkgver=1.1.3
|
||||
pkgrel=1
|
||||
pkgdesc="ZeroMQ is a software library that lets you quickly design and implement a fast message-based applications."
|
||||
url="https://github.com/mkoppanen/php-zmq"
|
||||
arch=('x86_64' 'i686')
|
||||
[[ $CARCH == 'i686' ]] && cd _arch=32bits || _arch=64bits
|
||||
license=('PHP')
|
||||
depends=('php' 'zeromq')
|
||||
makedepends=('gcc')
|
||||
backup=('etc/php/conf.d/zmq.ini')
|
||||
|
||||
source=(
|
||||
"https://pecl.php.net/get/zmq-$pkgver.tgz"
|
||||
)
|
||||
|
||||
sha256sums=('c492375818bd51b355352798fb94f04d6828c6aeda41ba813849624af74144ce')
|
||||
|
||||
build() {
|
||||
cd "$srcdir/zmq-$pkgver"
|
||||
|
||||
#Clean current compilation
|
||||
if [ -f Makefile ]; then
|
||||
make clean
|
||||
phpize --clean
|
||||
fi
|
||||
|
||||
phpize
|
||||
./configure --prefix=/usr
|
||||
make
|
||||
}
|
||||
|
||||
package() {
|
||||
cd "$srcdir/zmq-$pkgver"
|
||||
|
||||
make INSTALL_ROOT="$pkgdir" install
|
||||
|
||||
echo 'extension=zmq.so' > zmq.ini
|
||||
install -Dm644 zmq.ini "$pkgdir/etc/php/conf.d/zmq.ini"
|
||||
}
|
Loading…
Reference in New Issue
Block a user