mirror of
https://github.com/friendica/docker
synced 2025-02-08 00:41:44 +01:00
commit
5c92c61d1b
12 changed files with 81 additions and 69 deletions
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -6,6 +6,6 @@ while [ ! -f /var/www/html/.htconfig.php ]; do
|
|||
done
|
||||
|
||||
while true; do
|
||||
php -f /var/www/html/scripts/worker.php
|
||||
php -f /var/www/html/bin/worker.php
|
||||
sleep 10m
|
||||
done
|
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -6,6 +6,6 @@ while [ ! -f /var/www/html/.htconfig.php ]; do
|
|||
done
|
||||
|
||||
while true; do
|
||||
php -f /var/www/html/scripts/worker.php
|
||||
php -f /var/www/html/bin/worker.php
|
||||
sleep 10m
|
||||
done
|
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -6,6 +6,6 @@ while [ ! -f /var/www/html/.htconfig.php ]; do
|
|||
done
|
||||
|
||||
while true; do
|
||||
php -f /var/www/html/scripts/worker.php
|
||||
php -f /var/www/html/bin/worker.php
|
||||
sleep 10m
|
||||
done
|
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -141,7 +141,7 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
if version_greater "$image_version" "$installed_version" ||
|
||||
echo "$image_version" | grep -Eq '^.*\-dev'; then
|
||||
echo "$image_version" | grep -Eq '^.*\-dev|-rc'; then
|
||||
if [ "$(id -u)" -eq 0 ]; then
|
||||
rsync_options="-rlDog --chown=www-data:root"
|
||||
else
|
||||
|
@ -149,11 +149,16 @@ copy_sources() {
|
|||
fi
|
||||
|
||||
log 'Copying Friendica sources ('$image_version') from '\'$SOURCEDIR'/friendica'\'' to '\'$WORKDIR\'
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' --exclude='vendor' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
rsync $rsync_options --delete --exclude='.git' --exclude='photo' --exclude='proxy' --exclude='.htconfig.php' --exclude='home.*' $SOURCEDIR/friendica/ $WORKDIR/
|
||||
|
||||
if [ -f $WORKDIR/view/smarty3 ]; then
|
||||
chmod -R 777 $WORKDIR/view/smarty3
|
||||
fi
|
||||
|
||||
# the stable packages already have the whole vendor stuff in their images
|
||||
if echo "$FRIENDICA_VERSION" | grep -Eq '^.*(\-dev|-rc)'; then
|
||||
composer install
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -165,10 +170,9 @@ install() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Installing Friendica'
|
||||
composer install
|
||||
|
||||
copy_sources
|
||||
|
||||
if [ ! -f ${WORKDIR}/.htconfig.php ] &&
|
||||
[ -f ${SOURCEDIR}/config/htconfig.php ] &&
|
||||
|
@ -187,11 +191,10 @@ update() {
|
|||
return
|
||||
fi
|
||||
|
||||
copy_sources
|
||||
|
||||
log 'Upgrading Friendica'
|
||||
|
||||
composer install
|
||||
copy_sources
|
||||
|
||||
console dbstructure update
|
||||
}
|
||||
|
||||
|
|
|
@ -6,6 +6,6 @@ while [ ! -f /var/www/html/.htconfig.php ]; do
|
|||
done
|
||||
|
||||
while true; do
|
||||
php -f /var/www/html/%%DIR%%/worker.php
|
||||
php -f /var/www/html/bin/worker.php
|
||||
sleep 10m
|
||||
done
|
|
@ -32,11 +32,6 @@ declare -A install_extras=(
|
|||
['develop']=''
|
||||
)
|
||||
|
||||
declare -A bin_dir=(
|
||||
['stable']='scripts'
|
||||
['develop']='bin'
|
||||
)
|
||||
|
||||
variants=(
|
||||
apache
|
||||
fpm
|
||||
|
@ -91,10 +86,6 @@ function create_variant() {
|
|||
# Copy the bin directory
|
||||
cp -rT .bin "$dir/bin"
|
||||
|
||||
sed -ri -e '
|
||||
s/%%DIR%%/'"${bin_dir[$install_type]}"'/g;
|
||||
' "$dir/cron.sh"
|
||||
|
||||
travisEnvAmd64='\n - env: VERSION='"$1"' VARIANT='"$variant"' ARCH=amd64'"$travisEnvAmd64"
|
||||
for arch in i386 amd64; do
|
||||
travisEnv='\n - env: VERSION='"$1"' VARIANT='"$variant"' ARCH='"$arch$travisEnv"
|
||||
|
|
Loading…
Reference in a new issue