Skip to content

Instantly share code, notes, and snippets.

View samyranavela's full-sized avatar

Samy RANAVELA samyranavela

  • Soustons, France
View GitHub Profile
@samyranavela
samyranavela / install-rabbitmq.sh
Created December 11, 2017 20:49 — forked from yetanotherchris/install-rabbitmq.sh
RabbitMQ on Docker with admin UI
# AWS specific install of Docker
sudo yum update -y
sudo yum install -y docker
sudo service docker start
sudo usermod -a -G docker ec2-user
# exit the SSH session, login again
# Docker
docker run -d --hostname my-rabbit --name some-rabbit -p 4369:4369 -p 5671:5671 -p 5672:5672 -p 15672:15672 rabbitmq
@samyranavela
samyranavela / unixhttpc.go
Created December 11, 2017 13:19 — forked from teknoraver/unixhttpc.go
HTTP over Unix domain sockets in golang
package main
import (
"context"
"flag"
"fmt"
"io"
"net"
"net/http"
"os"
@samyranavela
samyranavela / .babelrc
Created November 9, 2017 12:28 — forked from andrewmunro/.babelrc
Sequelize cli with ES6
{
"presets": ["es2015"],
"plugins": [
"add-module-exports"
],
}
@samyranavela
samyranavela / ddd_cqrs_event-sourcing_in_php.md
Created October 12, 2017 09:51 — forked from jsor/ddd_cqrs_event-sourcing_in_php.md
DDD, CQRS and Event Sourcing in PHP

DDD, CQRS and Event Sourcing in PHP

  • Broadway - Infrastructure and testing helpers for creating CQRS and event sourced applications
  • EventCentric.Core - Event Sourcing and CQRS in PHP
  • LiteCQRS - Small convention based CQRS library for PHP
  • predaddy - Common DDD classes including an annotation driven message bus and tools for CQRS and Event Sourcing
  • ProophEventSourcing - Provides basic functionality for event-sourced aggregates
  • ProophEventStore - PHP 5.4+ EventStore Implementation
  • ProophServiceBus - PHP Enterprise Service Bus Implementation supporting CQRS and DDD
@samyranavela
samyranavela / build_pcntl.sh
Last active April 29, 2019 05:57 — forked from jbanety/build_pcntl.sh
Build PCNTL ext for MAMP PHP 7.1.8
#!/usr/bin/env bash
set -xo pipefail
# Command lines tools
xcode-select --install
# Install dependencies
brew install wget autoconf openssl libjpeg libpng lzlib curl imap-uw readline postgresql libxml2 mcrypt gettext libxslt homebrew/dupes/libiconv icu4c expat bison webp freetype
@samyranavela
samyranavela / command_exists.sh
Created September 21, 2017 14:19 — forked from gubatron/command_exists.sh
check if command exists (linux, mac)
function command_exists {
#this should be a very portable way of checking if something is on the path
#usage: "if command_exists foo; then echo it exists; fi"
type "$1" &> /dev/null
}
@samyranavela
samyranavela / gist:d0e70c2c3c603603edc11e54735beddb
Created June 10, 2016 07:33 — forked from archgrove/gist:6766129
Replays a git history, passing the repository at each state to a given script
#!/bin/bash
# Takes a repository and script from the command line
# and executes the script for each git log entry in reverse chronological order
# Use temporary files of the following format
TMP_TEMPLATE="/tmp/gitreplay-XXXXXXXX"
# Validate command line parameters
if [ -z $1 -o -z $2 ]; then
@samyranavela
samyranavela / start-stop-daemon-template
Created April 25, 2016 09:35 — forked from bcap/start-stop-daemon-template
Template file for creating linux services out of executables using the start-stop-daemon
#!/bin/bash
### BEGIN INIT INFO
# Provides: <service name>
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: <service description>
### END INIT INFO