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
wget -O - https://rpc.test4.gno.land/genesis | jq '.result.genesis' > genesis.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
package main | |
import ( | |
"fmt" | |
"reflect" | |
) | |
// Check if item is i an array for any type using reflection | |
func containsAny(items interface{}, value interface{}) bool { | |
itemsValue := reflect.ValueOf(items) |
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/sh | |
# Run remotely with -> source <(curl -s http://<remote-address-of-this-script>.sh) | |
set -e | |
# Run as su | |
if [ `id -u` -ne 0 ] | |
then | |
echo "You need to be root to run this script" | |
exit 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
> obj = { rows : [{count: 10}, {count:20}] } | |
{ rows: [ { count: 10 }, { count: 20 } ] } | |
> {rows: [{count: val}]} = obj | |
{ rows: [ { count: 10 }, { count: 20 } ] } | |
> val | |
10 | |
> {rows: [{count}]} = obj | |
{ rows: [ { count: 10 }, { count: 20 } ] } | |
> count | |
10 |
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/sh | |
# installing Docker CE on AWS AMI Linux | |
# Run remotely with -> source <(curl -s http://<remote-address-of-this-script>.sh) | |
set -e | |
# Run as su | |
if [ `id -u` -ne 0 ] | |
then |
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
docker run -d --name nginx -p 8080:80 -v $(pwd):/usr/share/nginx/html:ro nginx |
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/sh | |
# installing Docker CE on Ubuntu | |
# Run remotely with -> curl -sfL <http://_remote-address-of-this-script_> | sh - | |
## Compose not installed by default | |
set -e | |
# Run as su | |
if [ `id -u` -ne 0 ] |
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
docker ps -a | grep 'Exited' | awk '{print $1}' | xargs docker rm -f |
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
<!-- TODO: remove autodelete / insert fileAge --> | |
<file:connector name="inputfileObjectConnector" autoDelete="false" pollingFrequency="2000000" recursive="true"> <!-- autoDelete="false" --> | |
<service-overrides messageFactory="org.mule.transport.file.FileMuleMessageFactory" /> | |
</file:connector> | |
<flow name="edition"> | |
<!-- #1 - Read video file input --> | |
<file:inbound-endpoint path="${fs.path.root}${fs.path.untranscoded}" connector-ref="inputfileObjectConnector" comparator="org.mule.transport.file.comparator.OlderFirstComparator" > <!-- 900s -> 15min --> | |
<!-- <file:filename-wildcard-filter pattern=".avi,.mp4"/> -> does not work --> |
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
Mar 1 17:39:04 wimtv-dev kgd: last message repeated 3 times | |
Mar 1 17:39:04 wimtv-dev kgd: NFO - KGD: waiting connections | |
Mar 1 17:39:04 wimtv-dev kgd: DBG - CONN 87.241.57.98#346725017: listen loop start | |
Mar 1 17:39:04 wimtv-dev kgd: NFO - CONN 87.241.57.98#346725017 SOCKET: --- LISTEN --- | |
Mar 1 17:39:04 wimtv-dev kgd: DBG - ----- Reader::readSome --- PRIMA di recvFromSocket --- buffer size 1024 byte | |
Mar 1 17:39:04 wimtv-dev kgd: DBG - ----- Reader::recvFromSocket --- || NO FLAGS || | |
Mar 1 17:39:04 wimtv-dev kgd: DBG - ----- Reader::readSome --- recvFromSocket 149 byte | |
Mar 1 17:39:04 wimtv-dev kgd: NFO - CONN 87.241.57.98#346725017 SOCKET: --- Listen: received 149 byte | |
Mar 1 17:39:04 wimtv-dev kgd: NFO - CONN 87.241.57.98#346725017 SOCKET: --- Listen: next msg length 149 byte | |
Mar 1 17:39:04 wimtv-dev kgd: DBG - CONN 87.241.57.98#346725017 SOCKET: --- Listen: MSG => DESCRIBE rtsp://test.wim.tv:8554/enc_GvzETxPCiDjE.mp4 RTSP/1.0#015#012CSeq: 2#015#012User-Agent: LIVE555 Streaming Media v2010.10.28#0 |
NewerOlder