debian/littlebird-tc-core.postinst
changeset 110 7a0959f212e6
parent 81 39b02aed056b
child 115 dba222295f1f
equal deleted inserted replaced
109:1900286a9e74 110:7a0959f212e6
   101     test "$crt" && ucfr littlebird-tc-core "$crt"
   101     test "$crt" && ucfr littlebird-tc-core "$crt"
   102     test "$key" && ucfr littlebird-tc-core "$key"
   102     test "$key" && ucfr littlebird-tc-core "$key"
   103 
   103 
   104     # tweak the config file, but just the lines following a magical
   104     # tweak the config file, but just the lines following a magical
   105     # debconf line
   105     # debconf line
   106     cp /usr/share/doc/littlebird-tc/examples/apache/littlebird-tc.conf $tmp
   106     file=/usr/share/doc/littlebird-tc/examples/apache/littlebird-tc.conf
       
   107     if test -f "$file.gz"; then zcat "$file.gz" >$tmp
       
   108     else cp "$file" $tmp; fi
       
   109 
   107     perl - "$tmp" serveradmin="$serveradmin" servername="$servername" serverport="$serverport" \
   110     perl - "$tmp" serveradmin="$serveradmin" servername="$servername" serverport="$serverport" \
   108 	   crt="$crt" key="$key" <<'_'
   111 	   crt="$crt" key="$key" <<'_'
   109 	use strict;
   112 	use strict;
   110 	use warnings;
   113 	use warnings;
   111 	my $mark = '# debconf:';
   114 	my $mark = '# debconf:';