Skip to content

Instantly share code, notes, and snippets.

@yurkinx
yurkinx / nginx.conf
Created December 14, 2016 17:40 — forked from plentz/nginx.conf
Best nginx configuration for improved security(and performance). Complete blog post here http://tautt.com/best-nginx-configuration-for-security/
# to generate your dhparam.pem file, run in the terminal
openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048
@yurkinx
yurkinx / app.domainname
Created December 14, 2016 19:21 — forked from adityamenon/app.domainname
My preferred configuration for a Laravel 4 API endpoint running over PHP-FPM, when I need to talk to it with AngularJS.
server {
root /path/to/app/public;
index index.php;
server_name test.dev;
set $cors_headers "whatever-custom-headers,you-would-like";
# redirection to index.php
location / {
try_files $uri $uri/ /index.php?$query_string;
@yurkinx
yurkinx / helpers.php
Created March 12, 2017 19:17 — forked from mabasic/helpers.php
config_path function for Lumen framework
<?php
if ( ! function_exists('config_path'))
{
/**
* Get the configuration path.
*
* @param string $path
* @return string
*/
@yurkinx
yurkinx / leaflet-big-image-full.html
Created October 10, 2017 22:35 — forked from longhotsummer/leaflet-big-image-full.html
Full example of using leaflet to pan and zoom a big image, as described at http://kempe.net/blog/2014/06/14/leaflet-pan-zoom-image.html
<html>
<!-- See also: http://kempe.net/blog/2014/06/14/leaflet-pan-zoom-image.html -->
<head>
<link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7.3/leaflet.css"></script>
<style>
#image-map {
width: 100%;
height: 300px;
border: 1px solid #ccc;
margin-bottom: 10px;
flutter: Transition { currentState: AuthenticationUnauthenticated, event: AttachSession { token: eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6IjljMjJkMzI0NzA4YzVjOWM0ZDJlMTAzNzc4ODg3N2UyOTc0OGZmOGYifQ.eyJpc3MiOiJhdXRoLWFwaUBkb3NrYS1vcmJpdGEtY28taWwuaWFtLmdzZXJ2aWNlYWNjb3VudC5jb20iLCJhdWQiOiJodHRwczpcL1wvaWRlbnRpdHl0b29sa2l0Lmdvb2dsZWFwaXMuY29tXC9nb29nbGUuaWRlbnRpdHkuaWRlbnRpdHl0b29sa2l0LnYxLklkZW50aXR5VG9vbGtpdCIsImp0aSI6IjljMjJkMzI0NzA4YzVjOWM0ZDJlMTAzNzc4ODg3N2UyOTc0OGZmOGYiLCJpYXQiOjE1ODcxNDA4MDMsIm5iZiI6MTU4NzE0MDcyMywiZXhwIjoxNTg3MTQ0NDAzLCJzdWIiOiJhdXRoLWFwaUBkb3NrYS1vcmJpdGEtY28taWwuaWFtLmdzZXJ2aWNlYWNjb3VudC5jb20iLCJ1aWQiOjF9.Py0Hh9MVr3XeqK-ZUNE66Y2iHneDpt7sNRYmoKMVY3ENpBb_0MZplTqphd1OhfeUz5H1S5l_E5RXKSwbceSCJD9ucjmC47rstiLlXv1sOj30_lcj90U29WkiDAkhaTXcSe_Q8iqIUw80lF_OUndsG-R1qeYURzp3aso4nMdXwkbLpmLwisfS8KbjNcnf7cDt1C72lyy27s0KwcwNkttUhnUozLr_7VhH2ni9cAitCmyvvCQQ6e9FWyjmvLtK_Mb-yn4G8-oGGWOa_pphuwnuOC0fGZsB-_487Uy0EUSyKG5fUsKaiI7s-UOQykUpe70DwA0EsCrG24Pk-NMe6lvnUg, email: kileev@gmail.com <…>
path: sati