Skip to content

Instantly share code, notes, and snippets.

@tpokorra
Last active September 18, 2020 17:20
Show Gist options
  • Select an option

  • Save tpokorra/7113076 to your computer and use it in GitHub Desktop.

Select an option

Save tpokorra/7113076 to your computer and use it in GitHub Desktop.

Revisions

  1. tpokorra revised this gist Nov 13, 2013. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -43,7 +43,7 @@ cat > /etc/apt/sources.list.d/kolab.list <<FINISH
    deb http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/Development/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/ ./
    #deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/ ./
    FINISH

    wget http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/Release.key
  2. tpokorra revised this gist Nov 7, 2013. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -42,15 +42,15 @@ rm -Rf \
    cat > /etc/apt/sources.list.d/kolab.list <<FINISH
    deb http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Development/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/Development/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/ ./
    FINISH

    wget http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/Kolab:/3.1:/Development/Debian_7.0/Release.key
    wget http://obs.kolabsys.com:82/Kolab:/Development/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
  3. tpokorra revised this gist Nov 7, 2013. 1 changed file with 3 additions and 0 deletions.
    3 changes: 3 additions & 0 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -42,13 +42,16 @@ rm -Rf \
    cat > /etc/apt/sources.list.d/kolab.list <<FINISH
    deb http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Development/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/ ./
    FINISH

    wget http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/Kolab:/3.1:/Development/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key

  4. tpokorra revised this gist Oct 30, 2013. 1 changed file with 5 additions and 2 deletions.
    7 changes: 5 additions & 2 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -5,8 +5,11 @@ service dirsrv stop
    service wallace stop
    service apache2 stop

    sed -i "s#/usr/lib/x86_64-linux-gnu/dirsrv/perl);#/usr/lib/x86_64-linux-gnu/dirsrv/perl);\nuse lib qw(/usr/lib/dirsrv/perl);#g" /usr/sbin/remove-ds-admin
    /usr/sbin/remove-ds-admin -f -a -y
    if [ -f /usr/sbin/remove-ds-admin ]
    then
    sed -i "s#/usr/lib/x86_64-linux-gnu/dirsrv/perl);#/usr/lib/x86_64-linux-gnu/dirsrv/perl);\nuse lib qw(/usr/lib/dirsrv/perl);#g" /usr/sbin/remove-ds-admin
    /usr/sbin/remove-ds-admin -f -a -y
    fi

    apt-get remove 389\* cyrus-imapd\* postfix\* mysql-server\* roundcube\* pykolab\* kolab\* libkolab\* kolab-3\*

  5. tpokorra revised this gist Oct 30, 2013. 1 changed file with 0 additions and 4 deletions.
    4 changes: 0 additions & 4 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -58,8 +58,4 @@ FINISH
    apt-get update
    apt-get install kolab

    touch /etc/postfix/header_checks.inbound
    touch /etc/postfix/header_checks.submission
    touch /etc/postfix/header_checks.internal

    setup-kolab
  6. tpokorra revised this gist Oct 23, 2013. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -58,8 +58,8 @@ FINISH
    apt-get update
    apt-get install kolab

    touch /etc/postfix/header_checks/inbound
    touch /etc/postfix/header_checks/submission
    touch /etc/postfix/header_checks/internal
    touch /etc/postfix/header_checks.inbound
    touch /etc/postfix/header_checks.submission
    touch /etc/postfix/header_checks.internal

    setup-kolab
  7. tpokorra revised this gist Oct 23, 2013. 1 changed file with 6 additions and 2 deletions.
    8 changes: 6 additions & 2 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -10,9 +10,11 @@ sed -i "s#/usr/lib/x86_64-linux-gnu/dirsrv/perl);#/usr/lib/x86_64-linux-gnu/dirs

    apt-get remove 389\* cyrus-imapd\* postfix\* mysql-server\* roundcube\* pykolab\* kolab\* libkolab\* kolab-3\*

    # TODO problem reinstall? /etc/kolab/kolab.conf is gone after reinstall?
    # rm -Rf /etc/kolab/kolab.conf

    echo "deleting files..."
    rm -Rf \
    /etc/kolab/kolab.conf \
    /etc/postfix \
    /etc/dirsrv/slapd-* \
    /usr/lib64/dirsrv \
    @@ -56,6 +58,8 @@ FINISH
    apt-get update
    apt-get install kolab

    touch /etc/postfix/header_checks
    touch /etc/postfix/header_checks/inbound
    touch /etc/postfix/header_checks/submission
    touch /etc/postfix/header_checks/internal

    setup-kolab
  8. tpokorra revised this gist Oct 23, 2013. 1 changed file with 4 additions and 1 deletion.
    5 changes: 4 additions & 1 deletion reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -12,9 +12,9 @@ apt-get remove 389\* cyrus-imapd\* postfix\* mysql-server\* roundcube\* pykolab\

    echo "deleting files..."
    rm -Rf \
    /etc/dirsrv \
    /etc/kolab/kolab.conf \
    /etc/postfix \
    /etc/dirsrv/slapd-* \
    /usr/lib64/dirsrv \
    /usr/share/kolab-webadmin \
    /usr/share/roundcubemail \
    @@ -55,4 +55,7 @@ FINISH

    apt-get update
    apt-get install kolab

    touch /etc/postfix/header_checks

    setup-kolab
  9. tpokorra revised this gist Oct 23, 2013. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -37,7 +37,7 @@ rm -Rf \
    cat > /etc/apt/sources.list.d/kolab.list <<FINISH
    deb http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/ ./
    FINISH

    wget http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/Release.key
  10. tpokorra revised this gist Oct 23, 2013. 1 changed file with 3 additions and 0 deletions.
    3 changes: 3 additions & 0 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -5,6 +5,9 @@ service dirsrv stop
    service wallace stop
    service apache2 stop

    sed -i "s#/usr/lib/x86_64-linux-gnu/dirsrv/perl);#/usr/lib/x86_64-linux-gnu/dirsrv/perl);\nuse lib qw(/usr/lib/dirsrv/perl);#g" /usr/sbin/remove-ds-admin
    /usr/sbin/remove-ds-admin -f -a -y

    apt-get remove 389\* cyrus-imapd\* postfix\* mysql-server\* roundcube\* pykolab\* kolab\* libkolab\* kolab-3\*

    echo "deleting files..."
  11. tpokorra revised this gist Oct 23, 2013. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -18,6 +18,7 @@ rm -Rf \
    /usr/share/kolab-syncroton \
    /usr/share/kolab \
    /usr/share/dirsrv \
    /usr/share/389-* \
    /var/cache/dirsrv \
    /var/log/kolab* \
    /var/log/dirsrv \
  12. tpokorra revised this gist Oct 23, 2013. 1 changed file with 48 additions and 0 deletions.
    48 changes: 48 additions & 0 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,54 @@
    service kolab-server stop
    service kolab-saslauthd stop
    service cyrus-imapd stop
    service dirsrv stop
    service wallace stop
    service apache2 stop

    apt-get remove 389\* cyrus-imapd\* postfix\* mysql-server\* roundcube\* pykolab\* kolab\* libkolab\* kolab-3\*

    echo "deleting files..."
    rm -Rf \
    /etc/dirsrv \
    /etc/kolab/kolab.conf \
    /etc/postfix \
    /usr/lib64/dirsrv \
    /usr/share/kolab-webadmin \
    /usr/share/roundcubemail \
    /usr/share/kolab-syncroton \
    /usr/share/kolab \
    /usr/share/dirsrv \
    /var/cache/dirsrv \
    /var/log/kolab* \
    /var/log/dirsrv \
    /var/log/roundcube \
    /var/log/maillog \
    /var/lib/dirsrv \
    /var/lib/imap \
    /var/lib/kolab \
    /var/lib/mysql \
    /var/spool/imap \
    /var/spool/postfix

    cat > /etc/apt/sources.list.d/kolab.list <<FINISH
    deb http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/ ./
    FINISH

    wget http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key
    wget http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/Debian_7.0/Release.key
    apt-key add Release.key; rm -rf Release.key

    cat > /etc/apt/preferences.d/kolab <<FINISH
    Package: *
    Pin: origin obs.kolabsys.com
    Pin-Priority: 501
    FINISH

    apt-get update
    apt-get install kolab
    setup-kolab
  13. tpokorra created this gist Oct 23, 2013.
    6 changes: 6 additions & 0 deletions reinstallKolabDebian.sh
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    cat > /etc/apt/sources.list.d/kolab.list <<FINISH
    deb http://obs.kolabsys.com:82/Kolab:/3.1/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/Kolab:/3.1:/Updates/Debian_7.0/ ./
    deb http://obs.kolabsys.com:82/home:/tpokorra:/branches:/Kolab:/Development/ ./
    FINISH