Skip to content

Instantly share code, notes, and snippets.

@ryzy
ryzy / a.sh
Last active July 19, 2021 02:22
Compile OpenSSL 1.0.2 and HAProxy from the source on CentOS 7
# make sure you have these installed
yum install -y make gcc perl pcre-devel zlib-devel
@ryzy
ryzy / vhost.conf
Created March 12, 2016 23:54
Nginx with HTTP/2 support (and behind HAProxy with HTTP/2)
server {
listen 80 default_server;
listen 81 default_server http2 proxy_protocol; ## Needed when behind HAProxy with SSL termination + HTTP/2 support
listen 443 default_server ssl http2;
ssl_certificate /etc/ssl/dummy.crt;
ssl_certificate_key /etc/ssl/dummy.key;
root /data/www/default;
index index.html;
@ryzy
ryzy / nginx.repo
Last active September 19, 2019 07:16
Install Nginx 1.9.x on CentOS 7
# /etc/yum.repos.d/nginx.repo
[nginx]
name=nginx repo
baseurl=http://nginx.org/packages/mainline/centos/7/$basearch/
gpgcheck=0
enabled=1
@ryzy
ryzy / 1.sh
Last active March 12, 2016 23:40
SSL dummy cert for Nginx and HAProxy
# Generate all keys and cefiticates in /etc/ssl/ directory
openssl genrsa -out /etc/ssl/dummy.key 2048
openssl req -new -key /etc/ssl/dummy.key -out /etc/ssl/dummy.csr -subj "/C=GB/L=London/O=Company Ltd/CN=haproxy"
openssl x509 -req -days 3650 -in /etc/ssl/dummy.csr -signkey /etc/ssl/dummy.key -out /etc/ssl/dummy.crt
@ryzy
ryzy / right
Last active August 29, 2015 14:19
{
"image": {
"__flow_object_type": "TYPO3\\Media\\Domain\\Model\\ImageVariant",
"__identifier": "7dac7063-db28-d7c7-a8f0-383a3f0aec3e"
},
}
{
"_readme": [
"This file locks the dependencies of your project to a known state",
"Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"hash": "4773f480622f64505f94e877c67c97d0",
"packages": [
{
"name": "behat/transliterator",
-bash-4.2$ bin/behat -c Packages/Application/TYPO3.Neos/Tests/Behavior/behat.yml
Feature: Content module / Inline editing
In order to edit content easily
As an editor
I need a way to edit content inline
@fixtures @javascript
Scenario: Edit text of a content element with automatic save # Features/Content/InlineEditing.feature:7
Given I imported the site "TYPO3.NeosDemoTypo3Org" # FeatureContext::iImportedTheSite()
<node type="TYPO3.Neos.NodeTypes:Image" nodeName="node-5419a026ce3c4">
<properties>
<image __type="object" __classname="TYPO3\Media\Domain\Model\ImageVariant">
<processingInstructions><![CDATA[a:2:{i:0;a:2:{s:7:"command";s:4:"crop";s:7:"options";a:2:{s:5:"start";a:2:{s:1:"x";i:0;s:1:"y";i:0;}s:4:"size";a:2:{s:5:"width";i:377;s:6:"height";i:264;}}}i:1;a:2:{s:7:"command";s:6:"resize";s:7:"options";a:1:{s:4:"size";a:2:{s:5:"width";i:377;s:6:"height";i:264;}}}}]]></processingInstructions>
<originalImage __type="object" __classname="TYPO3\Media\Domain\Model\Image" __identifier="d4465756-e1d3-9940-68d7-6bf9a0d45e46">
<resource __type="object" __classname="TYPO3\Flow\Resource\Resource" __identifier="906a4546-e06c-bd0e-9a48-a31e3631db0c">
<filename>neos-login-screen.png</filename>
<hash>09aa7673b67948981f518be3a6fc34b13236d8b2</hash>
</resource>
</originalImage>
@ryzy
ryzy / user-data
Last active August 29, 2015 14:06
CoreOS on DO
#cloud-config
coreos:
etcd:
discovery: https://discovery.etcd.io/a406b834a9f6aa3517b485bd9e76d264
addr: $public_ipv4:4001
peer-addr: $private_ipv4:7001
fleet:
public-ip: $public_ipv4
@ryzy
ryzy / BlockGrid.ts2
Created April 16, 2014 19:45
How to wrap *each* children of TYPO3.Neos:ContentCollection into custom markup?
prototype(M12.Foundation:Content) < prototype(TYPO3.Neos:Content)
prototype(M12.Foundation:BlockGrid) < prototype(M12.Foundation:Content) {
blockGridContent = TYPO3.TypoScript:Collection {
collection = ${q(node).children('[instanceof TYPO3.Neos:ContentCollection]').children()}
itemName = 'gridItem'
itemRenderer = TYPO3.Neos:Content {
node = ${gridItem}
templatePath = 'resource://M12.Foundation/Private/Templates/NodeTypes/BlockGridItem.html'