Skip to content

Instantly share code, notes, and snippets.

Vladimir Lazarenko favoretti

Block or report user

Report or block favoretti

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
favoretti /
Created May 8, 2018 — forked from ugurerkan/
Zimbra 8.6.0 Letsencrypt SSL renew walkthrough.

Keybase proof

I hereby claim:

  • I am favoretti on github.
  • I am favoretti ( on keybase.
  • I have a public key whose fingerprint is 1C4E C3E7 980E 72C2 ACFE DB57 9D32 1AC6 564F 47CC

To claim this, I am signing this object:

View gist:6272899
def deployComponent(filepath, config, args, fabrichelper):
def signal_handler(signal, frame):
signal.signal(signal.SIGINT, signal_handler)
View gist:5221652
#include <stdio.h>
#include <unistd.h>
int main(void) {
char host[256];
if (gethostname(host, sizeof(host)) == 0)
host[sizeof(host) - 1] = '\0';
View gist:5221431
if (gethostname(host, sizeof(host)) == 0)
host[sizeof(host) - 1] = '\0';
strlcpy(host, "localhost", sizeof(host));
user_info[++i] = fmt_string("host", host);
if (user_info[i] == NULL)
errorx(1, _("unable to allocate memory"));
ud->host = user_info[i] + sizeof("host=") - 1;
favoretti / gist:4506529
Created Jan 10, 2013
opencsw collectd SMF manifest
View gist:4506529
<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<service_bundle type='manifest' name='collectd'>
<create_default_instance enabled='true' />
favoretti / gist:4506524
Created Jan 10, 2013
opencsw collectd SMF method
View gist:4506524
bash-3.2# cat /lib/svc/method/collectd
. /lib/svc/share/
case "$1" in
View gist:1562548
function __construct()
global $dataSourceName; //configuration variable, has all the information to connect to database
global $dbOpts; // configuration variable, has db operation options see config and PEAR DB module for details
global $logHandler;
global $logName;
global $logIdent;
global $logConf;
global $logLevel; //these are log configuration things. Make sure you've made your homework ;)
// mne nuzhny takie veschi
View gist:1562537
def cmpver(vA, vB):
def matchesCas(version):
return re.match("^.*\d+\.(\d{4})\.(\d+)\-(\d+)-[a-z0-9]+$", version)
if vA == vB: return 0
vA = vA.replace('-jetty-console', '')
vB = vB.replace('-jetty-console', '')
vA_Array = vA.split('-')
View gist:1562489
-(NSIndexSet *) lookupAll: (NSString *) theName
NSIndexSet *result = [book indexOfObjectsPassingTest:
^(id obj, NSUInteger idx, BOOL *stop)
if ([[obj name] caseInsensitiveCompare: theName] ==
return YES; // found a match, keep going
return NO; // keep looking
You can’t perform that action at this time.