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 | |
# generate a script ./clone-repos.sh from a list of repos fetched via Bitbucket API | |
# note: requires 'curl' and 'jq' to be installed | |
set -e | |
ONPREM_USER="" | |
ONPREM_PASS="" | |
URL="" |
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 -e | |
ERRORS=$(grep -rIL --exclude-dir=.git --exclude=*.png --exclude=*.jpg --exclude=*.crt --exclude=*.ttf . | wc -l) | |
if [ $ERRORS -gt "0" ]; then | |
echo '########################################' | |
echo 'Not allowed binaries are found in repo!' | |
echo 'Remove them:' | |
echo '' |
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
<?xml version="1.0" encoding="utf-8"?> | |
<testsuites> | |
<testsuite name="NPM Audit Advisories"> | |
<testcase name="MODERATE: 1091459 - Server-Side Request Forgery in Request"> | |
</testcase> | |
<testcase name="HIGH: 1091653 - xml2js is vulnerable to prototype pollution "> | |
</testcase> | |
</testsuite> | |
</testsuites> |
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/sh | |
staginlist=(`git diff --name-only --cached`) | |
binarylist=() | |
for filelist in ${staginlist[*]} | |
do | |
grep -Iq . ${filelist} | |
if [ $? -ne 0 ] | |
then |
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
/*global require,setInterval,console */ | |
const opcua = require("node-opcua"); | |
// Let's create an instance of OPCUAServer | |
const server = new opcua.OPCUAServer({ | |
port: 4334, // the port of the listening socket of the server | |
resourcePath: "/UA/MyLittleServer", // this path will be added to the endpoint resource name | |
buildInfo: { | |
productName: "MySampleServer1", | |
buildNumber: "7658", |
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 | |
TEXT="Hostname: $(hostname) - IP: $(hostname -I | awk '{print $1}')" | |
CHATID="" | |
TOKEN="" | |
curl -s -X POST \ | |
-H 'Content-Type: application/json' \ | |
-d '{"chat_id": "'"${CHATID}"'", "text": "'"${TEXT}"'", "disable_notification": false}' \ | |
https://api.telegram.org/bot${TOKEN}/sendMessage |
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
sudo proot -q qemu-arm -S /media/user/rootfs # <-mount path |
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 | |
# # ./nexus3-uploader.sh username password repo folder | |
url="http://domain.com:8081/nexus/repository/$repository/" | |
if [ $# -eq 0 ]; then | |
# Read Nexus3 Repository | |
echo -n "Nexus3 repository: " | |
read repository | |
# Read folder to upload |
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 config = { | |
"consumer_key": "00000000-0000-0000-0000-000000000000", | |
"consumerPrivateKey": "-----BEGIN RSA PRIVATE KEY-----\00000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n0000000000000000000000000000000000000000000000000000000000000000\n00000000000000000000000000000 |
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
Success: /var/log/boot/cloudSuccess: /var/log/boot/cloud[rancher@rancher ~]$ cat /var/log/boot/cloud-init-save.log | |
time="2019-08-14T09:41:33Z" level=debug msg="START: [cloud-init-save] in /" | |
time="2019-08-14T09:41:33Z" level=info msg="Running cloud-init-save" | |
time="2019-08-14T09:41:33Z" level=info msg=SaveCloudConfig | |
time="2019-08-14T09:41:33Z" level=debug msg="init: SaveCloudConfig(pre ApplyNetworkConfig): netconf.NetworkConfig{PreCmds:[]string(nil), DHCPTimeout:0, DNS:netconf.DNSConfig{Nameservers:[]string(nil), Search:[]string(nil)}, Interfaces:map[string]netconf.InterfaceConfig(nil), PostCmds:[]string(nil), HTTPProxy:"", HTTPSProxy:"", NoProxy:"", WifiNetworks:map[string]netconf.WifiNetworkConfig(nil), ModemNetworks:map[string]netconf.ModemNetworkConfig(nil)}" | |
time="2019-08-14T09:41:33Z" level=info msg="Apply Network Config" | |
time="2019-08-14T09:41:33Z" level=debug msg="Config: &netconf.NetworkConfig{PreCmds:[]string(nil), DHCPTimeout:10, DNS:netconf.DNSConfig{Nameservers:[]string(nil), Search:[]stri |
NewerOlder