mirror of
https://github.com/jessfraz/dockerfiles.git
synced 2024-11-23 11:31:49 +01:00
Fix build for SC2236 (#496)
* attempt to fix build correcting error message from travis ci In ./github-dev/cleanup-pr-branch line 5: if [[ ! -z "$TOKEN" ]]; then ^-- SC2236: Use -n instead of ! -z. * Update cleanup-pr-branch * Update release-email-notification corrected SC2236 * Update upload-assets correct SC2236 * Update sendemail Fix SC2236 * Update entrypoint.sh Fix SC2236 * Update run Fix SC2236
This commit is contained in:
parent
eceea18c85
commit
f81fc91bfd
|
@ -2,7 +2,7 @@
|
||||||
set -e
|
set -e
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
if [[ ! -z "$TOKEN" ]]; then
|
if [[ -n "$TOKEN" ]]; then
|
||||||
GITHUB_TOKEN=$TOKEN
|
GITHUB_TOKEN=$TOKEN
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ if [[ -z "$MAILGUN_API_KEY" ]]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$MAILGUN_DOMAIN" ]]; then
|
if [[ -n "$MAILGUN_DOMAIN" ]]; then
|
||||||
MAILGUN_DOMAIN_NAME=$MAILGUN_DOMAIN
|
MAILGUN_DOMAIN_NAME=$MAILGUN_DOMAIN
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
if [[ ! -z "$TOKEN" ]]; then
|
if [[ -n "$TOKEN" ]]; then
|
||||||
GITHUB_TOKEN=$TOKEN
|
GITHUB_TOKEN=$TOKEN
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,7 @@ if [[ -z "$MAILGUN_API_KEY" ]]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$MAILGUN_DOMAIN" ]]; then
|
if [[ -n "$MAILGUN_DOMAIN" ]]; then
|
||||||
MAILGUN_DOMAIN_NAME=$MAILGUN_DOMAIN
|
MAILGUN_DOMAIN_NAME=$MAILGUN_DOMAIN
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -47,7 +47,7 @@ if [ -d "$HOME/.gnupg" ]; then
|
||||||
if [ -f "/usr/share/doc/mutt/examples/gpg.rc" ]; then
|
if [ -f "/usr/share/doc/mutt/examples/gpg.rc" ]; then
|
||||||
echo 'source /usr/share/doc/mutt/examples/gpg.rc'
|
echo 'source /usr/share/doc/mutt/examples/gpg.rc'
|
||||||
fi
|
fi
|
||||||
if [ ! -z "$GPG_ID" ]; then
|
if [ -n "$GPG_ID" ]; then
|
||||||
echo "set pgp_sign_as = $GPG_ID"
|
echo "set pgp_sign_as = $GPG_ID"
|
||||||
fi
|
fi
|
||||||
echo 'set crypt_replysign=yes'
|
echo 'set crypt_replysign=yes'
|
||||||
|
|
|
@ -14,7 +14,7 @@ EOF
|
||||||
# shellcheck disable=SC1091
|
# shellcheck disable=SC1091
|
||||||
[ -f /etc/service/postfix/run.config ] && source /etc/service/postfix/run.config
|
[ -f /etc/service/postfix/run.config ] && source /etc/service/postfix/run.config
|
||||||
|
|
||||||
if [[ ! -z "$MAILNAME" ]]; then
|
if [[ -n "$MAILNAME" ]]; then
|
||||||
echo "$MAILNAME" > /etc/mailname
|
echo "$MAILNAME" > /etc/mailname
|
||||||
postconf -e myorigin="/etc/mailname"
|
postconf -e myorigin="/etc/mailname"
|
||||||
|
|
||||||
|
@ -25,15 +25,15 @@ if [[ ! -z "$MAILNAME" ]]; then
|
||||||
EOF
|
EOF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$MY_NETWORKS" ]]; then
|
if [[ -n "$MY_NETWORKS" ]]; then
|
||||||
postconf -e mynetworks="$MY_NETWORKS"
|
postconf -e mynetworks="$MY_NETWORKS"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$MY_DESTINATION" ]]; then
|
if [[ -n "$MY_DESTINATION" ]]; then
|
||||||
postconf -e mydestination="$MY_DESTINATION"
|
postconf -e mydestination="$MY_DESTINATION"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$ROOT_ALIAS" ]]; then
|
if [[ -n "$ROOT_ALIAS" ]]; then
|
||||||
if [[ -f /etc/aliases ]]; then
|
if [[ -f /etc/aliases ]]; then
|
||||||
sed -i '/^root:/d' /etc/aliases
|
sed -i '/^root:/d' /etc/aliases
|
||||||
fi
|
fi
|
||||||
|
@ -41,7 +41,7 @@ if [[ ! -z "$ROOT_ALIAS" ]]; then
|
||||||
newaliases
|
newaliases
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$RELAY" ]]; then
|
if [[ -n "$RELAY" ]]; then
|
||||||
# setup the relay
|
# setup the relay
|
||||||
cat >> /etc/postfix/main.cf <<- EOF
|
cat >> /etc/postfix/main.cf <<- EOF
|
||||||
relayhost = $RELAY
|
relayhost = $RELAY
|
||||||
|
@ -52,7 +52,7 @@ if [[ ! -z "$RELAY" ]]; then
|
||||||
EOF
|
EOF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$TLS" ]]; then
|
if [[ -n "$TLS" ]]; then
|
||||||
# setup tls
|
# setup tls
|
||||||
cat >> /etc/postfix/main.cf <<- EOF
|
cat >> /etc/postfix/main.cf <<- EOF
|
||||||
smtp_use_tls = yes
|
smtp_use_tls = yes
|
||||||
|
@ -60,7 +60,7 @@ if [[ ! -z "$TLS" ]]; then
|
||||||
EOF
|
EOF
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ! -z "$SASL_AUTH" ]]; then
|
if [[ -n "$SASL_AUTH" ]]; then
|
||||||
cat >> /etc/postfix/main.cf <<- EOF
|
cat >> /etc/postfix/main.cf <<- EOF
|
||||||
smtp_sasl_auth_enable = yes
|
smtp_sasl_auth_enable = yes
|
||||||
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
|
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
|
||||||
|
|
Loading…
Reference in New Issue
Block a user