This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# Upload mbox format email to zimbra | |
######################################################################## | |
# Libraries | |
######################################################################## | |
import email, email.Errors, mailbox, imaplib, sys, getopt | |
import os.path, StringIO, re, tempfile |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# SCRIPT 01 | |
root@Zabbix:/home/zabbix/scripts# cat deploy-choco.sh | |
#!/bin/bash | |
# This script detects the OS on a target machine and deploys the corresponding zabbix agent on Windows, Linux or Solaris | |
export LOG; LOG=/home/zabbix/scripts/logs/deploy.log | |
export DATE; DATE=`date +%F,%H:%M` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Version": "2012-10-17", | |
"Statement": [ | |
{ | |
"Effect": "Allow", | |
"Action": [ | |
"s3:ListBucket", | |
"s3:GetBucketLocation", | |
"s3:ListBucketMultipartUploads" | |
], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sudo apt-get install postfix -y && sudo apt-get install dovecot-imapd dovecot-pop3d -y |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1025914 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install makepasswd rcs perl-doc libio-tee-perl git libmail-imapclient-perl libdigest-md5-file-perl libterm-readkey-perl libfile-copy-recursive-perl build-essential make automake libunicode-string-perl | |
git clone git://github.com/imapsync/imapsync.git | |
sudo cpan | |
cpan> install Unicode::String | |
cd imapsync | |
mkdir dist | |
sudo make install | |
imapsync -v | |
--- | |
Start syncing |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tar cf files.lzma --lzma *.lzma.part |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Postfix mbox to Maildir format conversion | |
Often by default, postfix is configured to deliver email messages in mbox format. To convert mbox to Maildir | |
1. Edit /etc/postfix/main.cf and look for a line | |
# "Maildir/" for qmail-style delivery (the / is required). | |
home_mailbox = Maildir/ | |
2. if procmail is used by postfix to deliver locally change /etc/procmailrc add a line | |
DEFAULT=$HOME/Maildir/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo su - zimbra | |
# list all accounts and print out account name and aliases | |
for i in `zmprov -l gaa` ; do zmprov ga $i zimbraMailAlias ; done | |
# list all distribution lists and any members and/or aliases | |
for i in `zmprov gadl` ; do zmprov gdl $i zimbraMailAlias zimbraMailForwardingAddress ; done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
user www-data; | |
#worker_processes 4; | |
worker_processes auto; | |
pid /run/nginx.pid; | |
# number of file descriptors used for nginx | |
# the limit for the maximum FDs on the server is usually set by the OS. | |
# if you don't set FD's then OS settings will be used which is by default 2000 | |
worker_rlimit_nofile 100000; |