- Ensure you're on a non-SRM network. Access the remote machine first as:
sudo ssh -i yourkey.pem [email protected]
- Execute
nano /etc/ssh/sshd_config
and change#PORT 22
toPORT 443
. This ensures the remote machine has its SSH daemon listening on port 443. - Execute
sudo systemctl restart ssh.service
to restart the daemon. - Ensure that it is actually listening on port 443:
sudo netstat -nupt -l
. - Goto your AWS/DO/GCP web console and configure the Inbound ports. You generally would have to create a new Inbound rule (HTTPS-TCP-443-0.0.0.0/0).
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
import requests | |
import random | |
import os | |
def randomImageGenerator(width, height, counter): | |
myRandomNumber = int((random.random()*10000) // 10) | |
print("https://picsum.photos/id/{}/{}/{}".format(myRandomNumber, width, height)) | |
rawImageRawOriginal = requests.get("https://picsum.photos/id/{}/{}/{}".format(myRandomNumber, width, height)) | |
rawImageRawSmaller = requests.get("https://picsum.photos/id/{}/{}/{}".format(myRandomNumber, width // 10, height // 10)) |
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
/** | |
* @author zhixin wen <[email protected]> | |
* version: 1.10.0 | |
* https://github.com/wenzhixin/bootstrap-table/ | |
*/ | |
!function ($) { | |
'use strict'; | |
// TOOLS DEFINITION |
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
function keepMyServerAlive() { | |
var allMySites = ['https://google.com']; | |
for (var siteIndex in allMySites) { | |
var currentSite = allMySites[siteIndex]; | |
try { | |
var response = UrlFetchApp.fetch(currentSite); | |
Logger.log(response.getContentText()); |
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
def sendReportMail(emailAddress, passwordText, title, content): | |
import smtplib | |
from email.mime.text import MIMEText | |
smtp_ssl_host = 'smtp.yandex.com' # change to your own SMTP host | |
smtp_ssl_port = 465 | |
username = emailAddress | |
password = passwordText | |
sender = emailAddress | |
targets = ['[email protected]'] |
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
/** | |
* @author zhixin wen <[email protected]> | |
* extensions: https://github.com/kayalshri/tableExport.jquery.plugin | |
*/ | |
(function ($) { | |
'use strict'; | |
var TYPE_NAME = { | |
json: 'JSON', |