mirror of
https://github.com/YunoHost/install_script.git
synced 2024-09-03 20:06:25 +02:00
Merge pull request #24 from bleuchtang/master
improve autoinstall script
This commit is contained in:
commit
7a698fd700
1 changed files with 14 additions and 2 deletions
|
@ -6,6 +6,7 @@ ERR_FAIL_UPDATE=2
|
||||||
ERR_FAIL_INSTALL=3
|
ERR_FAIL_INSTALL=3
|
||||||
ERR_CANCEL_INSTALL=4
|
ERR_CANCEL_INSTALL=4
|
||||||
ERR_IMPOSSIBLE=-1
|
ERR_IMPOSSIBLE=-1
|
||||||
|
NO_ERR=0
|
||||||
|
|
||||||
function bck {
|
function bck {
|
||||||
FULLPATH="$(readlink -f "$1")"
|
FULLPATH="$(readlink -f "$1")"
|
||||||
|
@ -40,6 +41,12 @@ do
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
|
# Fix install on jessie
|
||||||
|
if [ $(lsb_release -c | awk '{print $2}') = jessie ];
|
||||||
|
then
|
||||||
|
apt-get install python-xmpp -y
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ ! -f /etc/yunohost/yunohost.conf ]]
|
if [[ ! -f /etc/yunohost/yunohost.conf ]]
|
||||||
then
|
then
|
||||||
mkdir /etc/yunohost/
|
mkdir /etc/yunohost/
|
||||||
|
@ -117,7 +124,12 @@ then
|
||||||
|
|
||||||
echo "Installation"
|
echo "Installation"
|
||||||
#add answer in debconf db
|
#add answer in debconf db
|
||||||
debconf-set-selections debconfv2
|
if [ $(lsb_release -c | awk '{print $2}') = jessie ];
|
||||||
|
then
|
||||||
|
debconf-set-selections $DIR/debconfjessie
|
||||||
|
else
|
||||||
|
debconf-set-selections $DIR/debconfv2
|
||||||
|
fi
|
||||||
|
|
||||||
#Install yunohost packages
|
#Install yunohost packages
|
||||||
apt-get -o Dpkg::Options::="--force-confold" \
|
apt-get -o Dpkg::Options::="--force-confold" \
|
||||||
|
@ -151,4 +163,4 @@ else
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Security : we shouldn't be able to exit here
|
# Security : we shouldn't be able to exit here
|
||||||
exit $ERR_IMPOSSIBLE
|
exit $NO_ERR
|
||||||
|
|
Loading…
Add table
Reference in a new issue