Add roundcubemail
This commit is contained in:
parent
dc24c75f94
commit
f6e537824d
9 changed files with 74 additions and 0 deletions
45
ressources/roundcubemail/debmaker
Executable file
45
ressources/roundcubemail/debmaker
Executable file
|
@ -0,0 +1,45 @@
|
|||
#!/bin/bash
|
||||
|
||||
VERSION=1.6.0
|
||||
|
||||
[ -e ./lib/function.sh ] && source ./lib/function.sh
|
||||
|
||||
APP=roundcubemail
|
||||
DEPOT=https://github.com/roundcube/roundcubemail.git
|
||||
GIT_VERSION=${VERSION}
|
||||
DEB_VERSION=${VERSION}-$(date +%Y%m%d%H%M)
|
||||
DEBIAN_VERSION_CODENAME=bullseye
|
||||
IMAGE_SIZE=4
|
||||
|
||||
STEP="minimum_package envinit default_prebuild build makedeb"
|
||||
|
||||
envinit() {
|
||||
apt-get update
|
||||
apt-get dist-upgrade -y
|
||||
apt-get install -y --no-install-recommends make curl npm nodejs jq php-xml php-pear php-mbstring unzip
|
||||
}
|
||||
|
||||
build() {
|
||||
cd /tmp/${APP}
|
||||
rm roundcubemail-*-git-complete.tar.gz
|
||||
PATH=$PATH:/tmp/${APP}/node_modules/.bin/
|
||||
sed 's/GITREMOTE=git/GITREMOTE=https/' Makefile -i
|
||||
sed "s/git clone --branch=\$(GITBRANCH)/git clone -b ${GIT_VERSION}/" Makefile -i
|
||||
make
|
||||
}
|
||||
|
||||
makedeb(){
|
||||
PATH_DEB=/tmp/src/rootfs
|
||||
|
||||
tar -zxf /tmp/${APP}/roundcubemail-*-git-complete.tar.gz --strip-components=1 -C ${PATH_DEB}/usr/share/roundcubemail/
|
||||
cp ${PATH_DEB}/usr/share/roundcubemail/config/config.inc.php.sample ${PATH_DEB}/etc/roundcubemail/config.inc.php
|
||||
mv ${PATH_DEB}/usr/share/roundcubemail/{CHANGELOG.md,INSTALL,LICENSE,README.md,SECURITY.md,UPGRADING} ${PATH_DEB}/usr/share/doc/roundcubemail/
|
||||
mv ${PATH_DEB}/usr/share/roundcubemail/{temp,logs} ${PATH_DEB}/var/lib/roundcubemail/
|
||||
|
||||
ln -s /var/lib/roundcubemail/temp ${PATH_DEB}/usr/share/roundcubemail/temp
|
||||
ln -s /var/lib/roundcubemail/logs ${PATH_DEB}/usr/share/roundcubemail/logs
|
||||
ln -s /etc/roundcubemail/config.inc.php ${PATH_DEB}/usr/share/roundcubemail/config/config.inc.php
|
||||
|
||||
sed -i "s/%VERSION%/$DEB_VERSION/" ${PATH_DEB}/DEBIAN/control
|
||||
fakeroot dpkg-deb -Z gzip --build ${PATH_DEB} /tmp/dist
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue