Let's start by creating entry for server in docker-compose.yaml
:
version: '2'
# version 2 of docker-compose is not "old" version, it's the actual version,
# see below for explanation:
# https://stackoverflow.com/a/53636006/961092
services:
Let's start by creating entry for server in docker-compose.yaml
:
version: '2'
# version 2 of docker-compose is not "old" version, it's the actual version,
# see below for explanation:
# https://stackoverflow.com/a/53636006/961092
services:
{ | |
"meta": { | |
"theme": "kendall", | |
"canonical": "https://github.com/paskal/terrty/blob/master/cv/resume.json" | |
}, | |
"basics": { | |
"name": "Dmitry Verkhoturov", | |
"label": "Senior Site Reliability Engineer", | |
"picture": "https://terrty.net/images/avatar.jpg", | |
"email": "[email protected]", |
import re | |
import logging | |
def expand_macro(zapi, itemid, hostid, macro): | |
"""Expand macro in passed string, recursively. Non-existent macro resolved to empty string. | |
Example: | |
# {$MACRO} resolves to "test macro in ${ENV} environment" | |
# {$ENV} resolves to "dev" | |
>>> print(expand_macro(zapi, 12345, 54321, "string with {$MACRO}")) |
SELECT m.hostid, | |
m.macro | |
FROM hostmacro AS m | |
WHERE | |
NOT (SELECT count(*) | |
FROM functions AS f | |
JOIN items AS i ON i.itemid = f.itemid | |
WHERE i.hostid = m.hostid | |
AND f.parameter LIKE concat('%',m.macro,'%')) | |
AND NOT |
#!/usr/bin/env python | |
# | |
# imap_cleaner.py | |
# | |
# Copyright 2012 Konstantin Shcherban <[email protected]> | |
# | |
# This program is free software; you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation; either version 2 of the License, or | |
# (at your option) any later version. |
# read more at https://terrty.net/2014/ssl-tls-in-nginx/ | |
# latest version on https://gist.github.com/paskal/628882bee1948ef126dd/126e4d1daeb5244aacbbd847c5247c2e293f6adf | |
# security test score: https://www.ssllabs.com/ssltest/analyze.html?d=terrty.net | |
# your nginx version might not have all directives included, test this configuration before using in production against your nginx: | |
# $ nginx -c /etc/nginx/nginx.conf -t | |
server { | |
# public key, contains your public key and class 1 certificate, to create: | |
# (example for startssl) | |
# $ (cat example.com.pem & wget -O - https://www.startssl.com/certs/class1/sha2/pem/sub.class1.server.sha2.ca.pem) | tee -a /etc/nginx/ssl/domain.pem > /dev/null |