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
const crypto = require('crypto'), | |
algorithm = 'aes-256-ctr', | |
password = 'd6F3Efeq'; | |
function encrypt(chunk) { | |
var cipher, | |
result, | |
iv; |
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
#Place this script in a directory w/ your private/public key/pair and run! | |
PowerShell.exe -ExecutionPolicy Bypass -File "C:\bypass\prompt\standard.ps1" 2>&1>$null | |
Add-WindowsCapability -Online -Name OpenSSH.Server | |
New-NetFirewallRule -Name sshd -DisplayName 'OpenSSH SSH Server' -Enabled True -Direction Inbound -Protocol TCP -Action Allow -LocalPort 22 -Program "%WINDIR%\System32\OpenSSH\sshd.exe" | |
#Must Enable ssh-agent before starting | |
Set-Service -Name ssh-agent -StartupType Automatic | |
Set-Service -Name sshd -StartupType Automatic |
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
const express = require('express') | |
const twilio = require('twilio') | |
const VoiceResponse = require('twilio').twiml.VoiceResponse; | |
const accountSid = 'AC3306*************************2f89'; | |
const authToken = '3a8a*********************b0697'; | |
const client = require('twilio')(accountSid, authToken); | |
const app = express() | |
const port = 1337 |
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
const { PerformanceObserver, performance } = require('perf_hooks'); | |
let t0 = performance.now() | |
/* | |
* Do process here for which you need to calculate time | |
* Example : | |
* let response = await axios.get() | |
**/ |
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
const azure = require('azure-storage') | |
const STORAGE_ACCOUNT_NAME = '<Your-Storage-Account-Name>'; | |
const ACCOUNT_ACCESS_KEY = '<Your-Storage-Account-Access-Key>'; | |
const blobSvc = azure.createBlobService(STORAGE_ACCOUNT_NAME, ACCOUNT_ACCESS_KEY) | |
const containerName = '<Your-Container-Name>' | |
const image = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAOAAAADgCAMAAAAt85rTAAAA81BMVEUANGb////MAAEAMWQANmkANWXQAAAAM2gAKmAALmLl7PAAI10AH1vVAADZAAAAG1oAN24AMWnx9fdJbZEAJl7I1+O5y9qcssbDAAAcPm3b6PFuiaZcfZ6wwtKSqb8MQXGSoba8CBOqt8YdL10wYIpLZIcgU4AUSXgzTXYAQXYsLVSjFisAFVqtDx9+nLZLJkuMFi04KlZ+jqSjEiOxCRiBHDRvHj98GTtfJUNVJUVOd5tYJUxvIDfNJSjz0tBDKE4SNFz77O3uu7tDJFLROTiMGSjnlJXddnXvpacADVnig4HXWl4AAFRcXnvQusA6LEtCCkE8jvjpAAARx0lEQVR4nN1dZ3viuBY2SHLBBmz6JCSBQPqk90l2MmVntt32/3/NlWwILrJ0ZAtC5v20+0wAvz7S6ToyKkvHRm9rdzRsT/cPdjA2DAPjnYP9aXs42t3qbSz9141lfnmvP5oeeU3PdW3HQQgZc9D/dhzbdem/HU1H/d4Sn2FZBLv9zQOvSYktWPGBKNGmd7DZ7y7nQZZBsLvd9ik3GbUETcrSb28vgaRugrX+8MjrSOXGl2XHOxr2a3ofSCvB2nY7UJMcR5JBe1snR30Ea33KrpDo0oKkHPXJURPBVm+IXac0uTkc |
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
export CUSTOMER_ID=cus_JV1oMxxxxxCCw | |
export SUBSCRIPTION_ID=sub_JV2G7xxxxxxBKFa | |
export STRIPE_TEST_TOKEN=sk_test_51HMsgYCFXNjKOD0xNWNyQ859bPyxxxxxxxxxxxxxxxxxxxxxxxxxOPZnZDm300IKhBt8tz | |
curl -u ${STRIPE_TEST_TOKEN}: \ | |
-d billing_cycle_anchor=now \ | |
https://api.stripe.com/v1/customers/${CUSTOMER_ID}/subscriptions/${SUBSCRIPTION_ID} |
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
let member = { | |
id: 178, | |
identifier: "User2", | |
firstName: "Training", | |
lastName: "User2", | |
inactiveDate: "2007-09-10T18:52:28Z", | |
inactiveFlag: true, | |
officeEmail: "[email protected]", | |
defaultEmail: "Office", | |
primaryEmail: "[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
#!/bin/bash | |
set -eu | |
PROJECT_REPO="/home/ubuntu/<project-folder-name>/<project-name>/deploy.git" | |
WORKING_DIR="/home/ubuntu/<project-folder-name>/<project-name>/workingdir" | |
while read oldrev newrev ref | |
do | |
echo "Ref $ref received. Deploying $newrev ..." | |
git --work-tree=${WORKING_DIR} --git-dir=${PROJECT_REPO} checkout -f $newrev |
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
name: Deploy to Github Pages | |
on: | |
push: | |
branches: | |
- develop | |
jobs: | |
deploy: | |
name: Deploy Application | |
runs-on: ubuntu-latest |