Skip to content

Instantly share code, notes, and snippets.

View mkherlakian's full-sized avatar

Maurice Kherlakian mkherlakian

View GitHub Profile
@mkherlakian
mkherlakian / currying.md
Created February 22, 2021 18:54 — forked from donnut/currying.md
TypeScript and currying

TypeScript and currying

In functional programming you often want to apply a function partly. A simple example is a function add. It would be nice if we could use add like:

var res2 = add(1, 3); // => 4

var add10To = add(10);
var res = add10To(5); // => 15

Extending Z-Ray

This is a guide aimed at providing some details on Z-ray extensibility API, and some methodologies/examples on how to write extensions.

Disclaimer: This an early DRAFT, information might be outdated by the time it is being read, or might just be plain wrong. At the time of writing there is no official documentation yet, so this is aimed at filling the blanks.

#Files

Extensions reside in zend-install-path/var/zray/extensions/

traceroute to pair12.php.net (76.75.200.106), 64 hops max, 52 byte packets
1 192.168.15.1 1.082 ms 1.758 ms 4.615 ms
2 192.168.2.1 1.785 ms 1.543 ms 1.573 ms
3 10.11.16.89 9.510 ms 7.133 ms 4.681 ms
4 * 10.178.206.158 9.969 ms 4.549 ms
5 10.178.206.159 12.885 ms 5.980 ms 4.614 ms
6 64.230.186.238 30.536 ms 29.829 ms 32.212 ms
7 67.69.246.34 28.265 ms 27.990 ms 28.660 ms
8 64.210.21.150 51.167 ms 51.955 ms 47.620 ms
9 192.168.4.201 44.940 ms 45.329 ms 42.864 ms
# -*- mode: ruby -*-
# vi: set ft=ruby :
# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
# All Vagrant configuration is done here. The most common configuration
# options are documented and commented below. For a complete reference,
# please see the online documentation at vagrantup.com.
@mkherlakian
mkherlakian / gist:6935844
Created October 11, 2013 14:41
Installing Zend Server with Vagrant using the Zend Server Chef cookbook

There are a couple of ways to fetch dependent cookbooks with Chef, one is with knife (which requires installing Knife) and the other manually. Since Zend Server only ahs 2 dependencies, manual download is easier.

Download the apt cookbook from http://community.opscode.com/cookbooks/apt and the yum cookbook from http://community.opscode.com/cookbooks/yum Then download the Zend Server cookbook from the repo:

http://community.opscode.com/cookbooks/zendserver

however if you have knife installed, you could fetch the deps also by using the command: knife cookbook site download apt