Skip to content

Instantly share code, notes, and snippets.

View exodus4d's full-sized avatar

Mark Friedrich exodus4d

View GitHub Profile
{
"config" : {
"id" : 22,
"name" : "first",
"icon" : "fa-desktop",
"created" : 1445793306,
"updated" : 1446991519,
"scope" : {
"id" : 1,
"name" : "wh",
We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
string(472) "��"Id";"Name";"Security";"MassTotal";"MassIndividual";"MassRegeneration";"MaxStableTime";
"1";"name1";"sec1";"masstot1";"massIndividual1";"massRegeneration1";"11";
"2";"name2";"sec2";"masstot2";"massIndividual2";"massRegeneration2";"22";"
@exodus4d
exodus4d / schema.php
Created December 23, 2015 02:15
MySQL Schema extension for f3-cortex
<?php
/**
* Created by PhpStorm.
* User: Exodus
* Date: 19.12.2015
* Time: 12:47
*
* This is an "on top" extension for "Schema Builder"
* see: https://github.com/ikkez/f3-schema-builder
*
@exodus4d
exodus4d / nginx.conf
Last active January 2, 2020 04:28
nginx.conf for Pathfinder (Nginx v1.11.8)
# nginx Configuration File
# http://wiki.nginx.org/Configuration
# Run as a less privileged user for security reasons.
user nginx nginx;
# How many worker threads to run;
# "auto" sets it to the number of CPU cores available in the system, and
# offers the best performance. Don't set it higher than the number of CPU
# cores if changing this parameter.
@exodus4d
exodus4d / pathfinder.conf
Last active August 27, 2020 03:33
pathfinder.conf for Pathfinder (Nginx v1.11.8)
# www to non-www redirect -- duplicate content is BAD:
# https://github.com/h5bp/html5-boilerplate/blob/5370479476dceae7cc3ea105946536d6bc0ee468/.htaccess#L362
# Choose between www and non-www, listen on the *wrong* one and redirect to
# the right one -- http://wiki.nginx.org/Pitfalls#Server_Name
# rewrite to HTTPS
server {
listen 80;
listen [::]:80;
<?php
/**
* Created by PhpStorm.
* User: Exodus
* Date: 23.01.2016
* Time: 17:18
*
* Handles access to EVE-Online "CREST API" and "SSO" auth functions
* - Add your API credentials in "environment.ini"
* - Check "PATHFINDER.API" in "pathfinder.ini" for correct API URLs
fastcgi_param PF-ENV-BASE '';
fastcgi_param PF-ENV-URL $scheme://$host;
fastcgi_param PF-ENV-DEBUG 3;
fastcgi_param PF-ENV-CACHE 'redis=localhost:6379';
fastcgi_param PF-ENV-DB_DNS 'mysql:host=localhost;port=3306;dbname=';
fastcgi_param PF-ENV-DB_NAME 'pathfinder';
fastcgi_param PF-ENV-DB_USER 'root';
fastcgi_param PF-ENV-DB_PASS '';
@exodus4d
exodus4d / second_map_2016_07_31.json
Created July 31, 2016 23:00
Pathfinder example map export JSON file
{
"config" : {
"id" : 2,
"name" : "second map",
"icon" : "fa-desktop",
"created" : 1469912015,
"updated" : 1469912085,
"scope" : {
"id" : 1,
"name" : "wh",
@exodus4d
exodus4d / PHP-FPM-respawn-issue.md
Last active January 6, 2018 16:56
Hallo Stefan L. :)

Ich habe den Fehler für das ständige restarten gefunden!

1. In der /etc/php-fpm.conf steht, dass ein PHP-FPM process neu gestartet wird bei 3 errors innherhalb von 1 Minute:
  • emergency_restart_threshold = 3
  • emergency_restart_interval = 1m

Als "Error" wird alles angesehen was sich in der /var/log/php-fpm/error.log findet mit prefix ERROR oder WARNING, das lässt sich über log_level = error anpassen, so dass nur noch `ERROR´ geloggt werden. Ansonsten werden auch solche standard Einträge als Error gelöscht:

[05-Jan-2018 21:04:17] WARNING: [pool www] server reached pm.max_children setting (28), consider raising it
@exodus4d
exodus4d / index.php
Last active September 9, 2018 13:16
Pathfinder HTTP2 ServerPush
<?php
abstract class Controller {
function beforeroute(\Base $f3, $params): bool {
if( !$f3->get('AJAX') ){
// singleton Resource() handels serverPush for static resources
$resource = Resource::instance();
$resource->setOption('filePath', [
'style' => $f3->get('BASE') . '/public/css/' . Config::getPathfinderData('version'),
'script' => $f3->get('BASE') . '/public/js/' . Config::getPathfinderData('version'),
'font' => $f3->get('BASE') . '/public/fonts',