This file contains 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 | |
set -o errexit | |
clear | |
printf "\n*** This script will download a cloud image and create a Proxmox VM template from it. ***\n\n" | |
### HOW TO USE | |
### Pre-req: | |
### - run on a Proxmox 6 server | |
### - a dhcp server should be active on vmbr1 |
This file contains 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
Tue Jul 9 04:15:00 2019 -04:00 | |
LENGTH : '154' | |
ACTION :[7] 'CONNECT' | |
DATABASE USER:[1] '/' | |
PRIVILEGE :[6] 'SYSDBA' | |
CLIENT USER:[5] 'rdsdb' | |
CLIENT TERMINAL:[0] '' | |
STATUS:[1] '0' | |
DBID:[10] '2635182666' |
This file contains 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
Outputs: | |
Logical ID: | |
Description: Information about the value | |
Value: !Ref MyOwnParameter | |
Export: | |
Name: Value to export |
This file contains 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 | |
path_to_folder=$1 | |
[[ -z `find "$path_to_folder" -mmin -1` ]] | |
if [ $? -eq 0 ] | |
then | |
echo -e "nothing has changed" | |
else | |
mail -s "Files in $path_to_folder has been changed" alan.kish38@gmail.com <<< "Files in $path_to_folder has been changed." | |
#echo -e "files has been changed" |
This file contains 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
ls /home/cpanel_username/mail/domain > list_email_accounts | sed -i 's/\///g' lis_email_accounts |
This file contains 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
# This is neat and simple example of virtual host configuration | |
# Rails application with LetsEncryptSSL running on nginx and | |
# Passenger. | |
server { | |
listen 80; | |
server_name example.com www.example.com; | |
return 301 https://$server_name$request_uri; | |
} |
This file contains 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
a |
This file contains 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
1. Get your favorite Linux distro, I am doing this on Lubuntu 16.04, becasue I am short on resources | |
2. Install it | |
3. Be sure that networking is in bridge mode | |
4. Call some terminals with Alt-Ctrl-T | |
5. Add some password to root user | |
~ sudo passwd root | |
6. Install Vi(m) if you don't want to break your fingers | |
~ apt-get install vim | |
7. Find out name of netwrok interface that you are using |
This file contains 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
This guide is assuming that you are actually running Windows Machine, which is bad, and can ocassionaly occur at your working place :) | |
This is written and tested on Ubuntu Server 16.04 LTS running as guest OS on Windows host inside VirtulBox. Network adapter is set up to a bridge network. If you changed your network adapter, don't forget to restart guest OS. Ususally sudo init 0 make this magic happen. | |
1. Add a password for root user | |
~ sudo passwd root | |
Enter password twice when prompter | |
2. Find out your local network IP address | |
~ ifconfig -a | |
// Everything different than lo device is actually your network device. Lo is local loopback device. Watch out for inet addr. That is your local IP address. | |
3. Change IP from dynamic to static | |
~ vi /etc/network/interfaces |
This file contains 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
[root@localhost asterisk]# tail -f full | |
[2016-08-18 00:01:37] VERBOSE[2634][C-0000000f] netsock2.c: Using SIP RTP TOS bits 184 | |
[2016-08-18 00:01:37] VERBOSE[2634][C-0000000f] netsock2.c: Using SIP RTP CoS mark 5 | |
[2016-08-18 00:01:37] VERBOSE[13972][C-0000000f] pbx.c: Executing [0921929444@from-internal:1] Macro("SIP/300-00000014", "user-callerid,LIMIT,EXTERNAL,") in new stack | |
[2016-08-18 00:01:37] VERBOSE[13972][C-0000000f] pbx.c: Executing [s@macro-user-callerid:1] Set("SIP/300-00000014", "TOUCH_MONITOR=1471471297.20") in new stack | |
[2016-08-18 00:01:37] VERBOSE[13972][C-0000000f] pbx.c: Executing [s@macro-user-callerid:2] Set("SIP/300-00000014", "AMPUSER=300") in new stack | |
[2016-08-18 00:01:37] VERBOSE[13972][C-0000000f] pbx.c: Executing [s@macro-user-callerid:3] GotoIf("SIP/300-00000014", "0?report") in new stack | |
[2016-08-18 00:01:37] VERBOSE[13972][C-0000000f] pbx.c: Executing [s@macro-user-callerid:4] ExecIf("SIP/300-00000014", "1?Set(REALCALLERIDNUM=300)") in new stack | |
[2016-08-18 00:01:37] VERBOSE[13972 |
NewerOlder