sudo apt-get install python3-pip
sudo pip3 install virtualenv
#!/usr/local/env bash | |
# Register digitalocean with free credit https://m.do.co/c/4879bb02d178 | |
# Create vps with 5usd price | |
# Tested on Ubuntu 18.04, Debian 9.6 | |
# How to... | |
# 1. Save this file as softether-installer.sh | |
# 2. chmod +x softether-installer.sh | |
# 3. Run bash file | |
# > ./softether-installer.sh | |
# Or just |
#!/bin/bash | |
filename="/path/to/your/file.log" | |
subject="Subject of my email" | |
txtmessage="This is the message I want to send" | |
{ | |
sleep 1; | |
echo "EHLO mydomain.intra" | |
sleep 1; |
cat /tmp/list.cuid.txt | while read line ; do echo $( echo "$line;"$(ldapsearch -H ldaps://$ldapserver -w $ldappassword -b "dc=domain,dc=exemple,dc=com" -D "CN="$cuid",OU=Utilisateurs,OU=France Telecom,DC=domain,DC=exemple,DC=com" -s sub "CN=$line" | grep "displayName:\|department:\|telephoneNumber:\|mail:" | awk -F ":" '{ $1 ~ "telephone ; print $2 }' | tr '\n' ';' ) ); done | tee /tmp/list.cuid.csv |
################################################################################ | |
# Send E-mail from eml file in PowerShell | |
# Tested on PowerShell 2.0 | |
# | |
# Usage: | |
# 1. Configure the variables defined in Main() | |
# $server = "localhost" | |
# $port = "25" | |
# $mailfrom = "from@example.com" | |
# $rcptto = "to@example.com" |