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
public class DeskSample | |
{ | |
private static String OAUTH_KEY = 'youroauthkey'; | |
private static String OAUTH_SECRET = 'youroauthsecret'; | |
private static String ACCESS_TOKEN = 'youraccesstoken'; | |
private static String ACCESS_TOKEN_SECRET = 'youraccesstokensecret'; | |
public static String DESK_SITENAME = 'yoursite'; | |
public static Void doRequest() |
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
require 'desk_api' | |
DeskApi.configure do |config| | |
config.username = 'user@example.com' | |
config.password = 'Example1' | |
config.endpoint = 'https://sample.desk.com' | |
end | |
customer = DeskApi.customers.create({ | |
first_name: 'Test', |
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
from Crypto import Random | |
from Crypto.Cipher import AES | |
from datetime import datetime, timedelta | |
from isodate import datetime_isoformat | |
import base64 | |
import hashlib | |
import hmac | |
import urllib | |
import json |
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 | |
echo "Creating a new scratch org" | |
sfdx force:org:create -f config/project-scratch-def.json -a $1 --setdefaultusername --durationdays 30 | |
sfdx scmt:audit:enable -u $1 | |
echo "Pushing source" | |
sfdx force:source:push -f -u $1 | |
sfdx force:user:permset:assign --permsetname SCMT_Audit -u $1 | |
sfdx force:data:record:update -s User -w "firstname='User'" -v "UserPermissionsKnowledgeUser=true" -u $1 | |
sfdx force:org:open -u $1 |
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
Show hidden characters
{ | |
"env": { | |
"browser": true | |
}, | |
"parserOptions": { | |
"ecmaVersion": 5 | |
}, | |
"globals": { | |
"$A": true, | |
"AuraContext": true, |
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
version: '3' | |
services: | |
nginx: | |
image: nginx:alpine | |
ports: | |
- '80:80' | |
- '443:443' | |
restart: always |
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
FROM nginx:alpine | |
COPY nginx.vh.default.conf /etc/nginx/conf.d/default.conf |
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
version: '3' | |
services: | |
logger: | |
image: gliderlabs/logspout | |
volumes: | |
- '/var/run/docker.sock:/var/run/docker.sock' | |
command: "syslog+tls://${PAPERTRAIL_URL}" | |
restart: always |
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
sudo service ssh restart |
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
# /etc/ssh/sshd_config | |
# ... | |
# Authentication | |
LoginGraceTime 120 | |
PermitRootLogin no | |
StrictModes yes | |
# ... |