Skip to content

Instantly share code, notes, and snippets.

View antonmry's full-sized avatar

Antón Rodríguez antonmry

View GitHub Profile
@antonmry
antonmry / cards.go
Created June 1, 2016 21:43
dailyprogrammer: Network and Cards: Part 1, The network
package main
// See https://www.reddit.com/r/dailyprogrammer/comments/4knivr/20160523_challenge_268_easy_network_and_cards/
import (
"flag"
"fmt"
"net"
"os"
"sync"
@antonmry
antonmry / restcomm_rc_range.yml
Created May 21, 2016 13:48
RestComm & Kubernetes with port ranges
apiVersion: v1
kind: ReplicationController
metadata:
name: restcomm-core-controller
spec:
replicas: 1
selector:
app: restcomm-core
template:
metadata:
@antonmry
antonmry / delete_label_from_issues.sh
Created May 19, 2016 18:03
Delete one label from the issues already done in one repository
ghi list -L LABELTOBEDELETED -s closed -- YOURORGANIZATION/YOURREPO | sed -n '/^[ 0-9 ]/p' | sed -r 's/([^0-9]*([0-9]*)){1}.*/\2/' | xargs -I %issue sh -c 'ghi label "%issue" -d "LABELTOBEDELETED" -- YOURORGANIZATION/YOURREPO'
@antonmry
antonmry / restcomm_rc.yml
Last active April 30, 2016 14:20
restcomm_rc.yml by @adimania
apiVersion: v1
kind: ReplicationController
metadata:
name: restcomm-core-controller
spec:
replicas: 1
selector:
app: restcomm-core
template:
metadata:
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Action": [
"s3:GetBucketLocation",
"s3:ListAllMyBuckets"
],
"Resource": "arn:aws:s3:::*"
{
"requiresAttributes": [],
"taskDefinitionArn": "arn:aws:ecs:eu-west-1:742070958976:task-definition/restcomm-task-ayuste:4",
"status": "ACTIVE",
"revision": 4,
"containerDefinitions": [
{
"volumesFrom": [],
"memory": 3000,
"extraHosts": null,
@antonmry
antonmry / Call 1234
Last active April 26, 2016 11:58
Restcomm using Amazon ECS
19:35:02,214 INFO [gov.nist.javax.sip.stack.SIPTransactionStack] (SIP-TCP-Core-PipelineThreadpool-9) <message
from="91.116.135.52:49532"
to="172.17.0.3:5063"
time="1461612902214"
isSender="false"
transactionId="z9hg4bk-363539-444588cfc4915bd2042802134f4b13bb"
callId="1461612902182"
firstLine="REGISTER sip:ec2-54-194-81-211.eu-west-1.compute.amazonaws.com SIP/2.0"
>
<![CDATA[REGISTER sip:ec2-54-194-81-211.eu-west-1.compute.amazonaws.com SIP/2.0
@antonmry
antonmry / command.sh
Created October 15, 2015 11:57
Created gradle dependencies directly from bash
for i in *.jar; do echo "providedCompile files(\"\${projectDir}/src/main/resources/$i\")"; done
@antonmry
antonmry / Installation of Fedora 23 on Dell XPS 13 2015 (9343) .md
Last active August 21, 2017 14:00
Installation of Fedora 21 on Dell XPS 13 Developer Edition 2015
@antonmry
antonmry / Replace.sh
Created February 3, 2015 09:37
Replace a string recursively
grep -ilr '10.0.2.15' * | xargs -i@ sed -i 's/10.0.2.15/ocsg/g' @