core/ca-certificates/ca-certificates.install
2010-05-16 15:08:55 +00:00

22 lines
488 B
Plaintext

post_install() {
usr/sbin/update-ca-certificates --fresh
}
post_upgrade() {
usr/sbin/update-ca-certificates --fresh
}
pre_remove() {
# clean up certificates
local _backup=$(mktemp)
mv etc/ca-certificates.conf ${_backup}
echo > etc/ca-certificates.conf
usr/sbin/update-ca-certificates --fresh
mv ${_backup} etc/ca-certificates.conf
}
post_remove() {
# remove the cert file if it is empty
[[ -s etc/ssl/certs/ca-certificates.crt ]] || rm -f etc/ssl/certs/ca-certificates.crt
}