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
//Define variable before init ActionHero SpecHelper | |
api.config.upload_config.storage_path = 'c:\\tmp' | |
// Run API | |
let {fileUpLoad} = await api.specHelper.runAction('SuperFileUpload') | |
// Run Async/Awaith Test API | |
await chai.request('http://localhost:' + api.config.servers.web.port) | |
// API end point | |
/* res.body return JSON object from an API | |
* define object or key-value you want to check ( property and value ) |
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
version: "2" | |
services: | |
verdaccio: | |
image: verdaccio/verdaccio | |
hostname: npm-registry | |
ports: | |
- 4873:4873 | |
# volumes: | |
# - /etc/verdaccio/conf:/verdaccio/conf | |
# - /var/cache/verdaccio/storage:/verdaccio/storage |
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
{ | |
"events": [ | |
{ | |
"type": "message", | |
"replyToken": "e772d6f6b3ce4f198f58a0671889ac55", | |
"source": { | |
"userId": "U55aa364949999f07b2f7b6b9de0ef07", | |
"type": "user" | |
}, | |
"timestamp": 1540374281107, |
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
git clone [email protected]:cloudflare/kyototycoon.git | |
sudo dnf install openssl-devel kyotocabinet-devel | |
./configure | |
make | |
sudo make install | |
echo /usr/local/lib > /etc/ld.so.conf.d/kyoto-tycoon.conf | |
sudo ldconfig |
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
FROM alpine:3.7 | |
MAINTAINER Narate Ketram <[email protected]> | |
RUN apk update && apk add git build-base lua5.1-dev lzo-dev zlib-dev | |
RUN cd /tmp && \ | |
git clone https://github.com/narate/kyoto.git && \ | |
cd kyoto && \ | |
make && \ | |
make install && \ | |
make clean && \ |
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
# Restart API server | |
systemctl restart snap.microk8s.daemon-apiserverd | |
# Apply rules | |
kubectl apply -f rbac-microk8s.yml | |
# Check running | |
kubectl get clusterroles cluster-admin |
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 | |
wget https://dl.pstmn.io/download/latest/linux64 -O postman-linux-x64.tar.gz | |
sudo tar xvzf postman-linux-x64.tar.gz -C /opt | |
sudo ln -s /opt/Postman/Postman /usr/bin/postman | |
cat << EOF > ~/.local/share/applications/postman2.desktop | |
[Desktop Entry] | |
Name=Postman | |
GenericName=API Client |
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
// Require the framework and instantiate it | |
const fastify = require('fastify')({ | |
logger: true | |
}) | |
const post_schema = { | |
method: 'GET', | |
schema: { | |
body: { | |
type: 'object', |
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
#!/usr/bin/env python | |
from github import Github | |
#https://github.com/settings/tokens | |
g = Github("4a3d3c5ba12e402015dcdcf55c312e0614xxxxx888s") | |
folks_repo = [ repo for repo in g.get_user().get_repos() if repo.fork == True] | |
for repo in folks_repo: | |
repo.delete() |