Install Google Cloud SDK

To install Google Cloud SDK on Ubuntu/Debian, add repo export CLOUD_SDK_REPO=”cloud-sdk-$(lsb_release -c -s)” echo “deb http://packages.cloud.google.com/apt $CLOUD_SDK_REPO main” > /etc/apt/sources.list.d/google-cloud-sdk.list Add Key curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add – Install with apt-get update apt-get install google-cloud-sdk Before you can use gcloud command, you need to run gcloud init gsutil Google Cloud Google Cloud Storage

gsutil

gsutil is part of Google Cloud SDK allow you to work with Google Cloud Storage. Configure Before you can use gsutil, run gcloud auth login You will be given a special URL, open the link in browser, login to your google cloud account. Then you get a code, copy and paste it in terminal. Now … Read more

azure

Install Azure CLI on Ubuntu az – Microsoft Azure Cross-platform Command Line Interface Microsoft Azure Set rDNS Swap Boot Disk in Azure VM

speedtest

https://gtmetrix.com https://tools.pingdom.com https://developers.google.com/speed/pagespeed/insights/ Test network performance with iperf Install SpeedTest cli on Ubuntu

Microsoft Azure Set rDNS

To set rDNS for an IP, first make it static. Then use Azure CLI boby@hon-pc-01:~$ az network public-ip update –resource-group serverok –name ok-vmPublicIP –reverse-fqdn azure-rdns.serverok.in –dns-name ok-vm { “dnsSettings”: { “domainNameLabel”: “ok-vm”, “fqdn”: “ok-vm.southeastasia.cloudapp.azure.com”, “reverseFqdn”: “azure-rdns.serverok.in” }, “etag”: “W/\”1046148c-e501-49e0-a673-942b75dd71ad\””, “id”: “/subscriptions/7adb2f54-bc45-4d4d-a5ec-321ca213d39d/resourceGroups/serverok/providers/Microsoft.Network/publicIPAddresses/ok-vmPublicIP”, “idleTimeoutInMinutes”: 4, “ipAddress”: “52.187.107.150”, “ipConfiguration”: { “etag”: null, “id”: “/subscriptions/7adb2f54-bc45-4d4d-a5ec-321ca213d39d/resourceGroups/serverok/providers/Microsoft.Network/networkInterfaces/ok-vmVMNic/ipConfigurations/ipconfigok-vm”, “name”: null, “privateIpAddress”: null, … Read more

Plesk Nginx fail to start on boot

On a Debian Server with Plesk Control Panel, Nginx did not start on boot. On checking status, i get root@server:~# systemctl status nginx * nginx.service – Startup script for nginx service Loaded: loaded (/lib/systemd/system/nginx.service; enabled) Active: failed (Result: exit-code) since Mon 2018-01-22 18:30:19 CET; 2min 21s ago Process: 700 ExecStartPre=/usr/sbin/nginx -t (code=exited, status=1/FAILURE) Process: 646 … Read more

Scripts

User Authentication (SSO) https://www.keycloak.org Advertising https://www.revive-adserver.com Ecommerce Video Sharing Traffic Monitoring Employee Monitoring Social Media Misc Scripts

Magento 1.9 Nginx Configuration

Here is Nginx + php-fpm config for Magento 1.9 on Ubuntu 16.04/Debian 9. server { listen 80; server_name mysite.com www.mysite.com; root /home/mysite.com/public_html/; listen 443 ssl http2; ssl on; ssl_certificate /etc/letsencrypt/live/mysite.com/fullchain1.pem; ssl_certificate_key /etc/letsencrypt/live/mysite.com/privkey1.pem; location / { index index.html index.php; try_files $uri $uri/ @handler; expires 30d; } ## These locations would be hidden by .htaccess normally location … Read more

x2go

Keyboard shortcuts for X2Go Client Ctrl + Alt + T: terminate session / disconnect Ctrl + Alt + F: toggle fullscreen/windowed Ctrl + Alt + M: minimize or maximize fullscreen window Ctrl + Alt + arrow keys: move viewport (when remote screen is bigger than client window) Install Client Install x2Go Client in Ubuntu Install … Read more

Install x2go server in Debian 9

Add repo vi /etc/apt/sources.list.d/x2go.list Add deb http://packages.x2go.org/debian stretch extras main deb-src http://packages.x2go.org/debian stretch extras main Add key apt-key adv –recv-keys –keyserver keys.gnupg.net E1F958385BFE2B6E Install X2Go server with apt-get update apt-get install x2goserver x2goserver-xsession -y Now you need to install one of the Desktop, it is better use XFCE on remote servers. apt -y install xfce4 … Read more

Amazon Linux Invalid command SSLEngine

On Amazon Linux, when restarting Apache server, i get error [root@ip-172-16-20-44 conf.d]# service httpd restart Stopping httpd: [ OK ] Starting httpd: AH00526: Syntax error on line 5 of /etc/httpd/conf.d/sendy.mayflower.com.my-le-ssl.conf: Invalid command ‘SSLEngine’, perhaps misspelled or defined by a module not included in the server configuration [FAILED] [root@ip-172-16-20-44 conf.d]# This is because SSL module was … Read more