Fedora 33 - make DNS (systemd-resolved) working with NetworkManager's ForitSSL VPN connections

Published on Author admin

In Fedora 33 there is a systemd-resolved service enabled by default. Use following steps to make DSN working after establishing FortiSSL VPN connection using Network Manager (using NetworkManager-fortisslvpn-gnome plugin). Assuming that "ppp0" is you virtual network interface for VPN connection, you can set X.X.X.X and Y.Y.Y.Y as DNS servers: resolvectl dns ppp0 X.X.X.X Y.Y.Y.Y Add… Continue reading Fedora 33 - make DNS (systemd-resolved) working with NetworkManager's ForitSSL VPN connections

AWS S3 backup script

Published on Author admin

Start with updating AWS CLI tool: pip3 install awscli --upgrade --user Script for backing up data into your AWS S3 bucket: #!/bin/bash pathtobackup='/home/USERNAME/data/' pathtoarchivefile='/home/USERNAME' filenameprefix='backup-nextcloud' secret='secretpassword' awsbucket='awsbucket-name' date=`date --iso-8601` archivefilename=$filenameprefix-$date.7z echo echo "Performing backup of $pathtobackup to s3://$awsbucket/$archivefilename" echo echo `date -Is` echo "Compressing $pathtobackup to $pathtoarchivefile/$archivefilename" echo 7za a $pathtoarchivefile/$archivefilename $pathtobackup -p$secret echo echo… Continue reading AWS S3 backup script

[Raspberry Pi] script for auto reconnecting WiFi connection

Published on Author admin

Create script file: touch /home/volumio/wifi-reconnect.sh with following content: #!/bin/bash   SSID=$(/sbin/iwgetid --raw) if [ -z "$SSID" ] then     echo "`date -Is` WiFi interface is down, trying to reconnect" >> /home/volumio/wifi-log.txt     systemctl restart wireless fi echo "WiFi check finished" Make new file executable: chmod +x /home/volumio/wifi-reconnect.sh Install cron: sudo apt-get install cron… Continue reading [Raspberry Pi] script for auto reconnecting WiFi connection

Using AWS EC2 CLI - part 2

Published on Author admin

Using AWS EC2 CLI - part 2 Script for checking VMs status: https://github.com/openterprise/scripts/blob/master/aws-status.sh Example user data file script: https://github.com/openterprise/scripts/blob/master/aws-user-data.sh #create VM centos aws ec2 run-instances --image-id ami-18f8df7d --security-group-ids sg-ID --subnet-id subnet-ID --count 1 --instance-type t2.micro --key-name KEY-NAME --user-data file://aws-user-data.sh --block-device-mappings 'DeviceName=/dev/sda1,Ebs={VolumeSize=10,DeleteOnTermination=false}' --query 'Instances[0].InstanceId' #stop ALL instances (only those are running) aws ec2 stop-instances --instance-ids `aws… Continue reading Using AWS EC2 CLI - part 2