Skip to content

Instantly share code, notes, and snippets.

View hrvoj3e's full-sized avatar
💻
Cloning ...

Hrvoje hrvoj3e

💻
Cloning ...
View GitHub Profile
@hrvoj3e
hrvoj3e / ubuntu-1804-lacp-bonding.md
Created March 9, 2020 16:45 — forked from PhilipSchmid/ubuntu-1804-lacp-bonding.md
Ubuntu 18.04 LACP Network Interface Bonding

Interface bonding

Configure an LACP active network interface bonding on Ubuntu 18.04 using netplan:

root@srv01:~# mv /etc/netplan/50-cloud-init.yaml /etc/netplan/01-netcfg.yaml
root@srv01:~# cat /etc/netplan/01-netcfg.yaml 
network:
    version: 2
    renderer: networkd
 ethernets:
@hrvoj3e
hrvoj3e / nginx.conf
Created August 19, 2020 06:23 — forked from sgomez84/nginx.conf
Nginx Proxy Pass to PHP-FPM
upstream phpfpm {
#server unix:/var/run/php5-fpm.sock;
#avoid sockets for nginx-fpm on Linux, they are good for BSD
server 127.0.0.1:9000;
}
server {
listen 8080;
server_name sumhr.com;
rewrite ^(.*) $scheme://www.sumhr.com$1 permanent;
@hrvoj3e
hrvoj3e / AuthServiceProvider.php
Created February 8, 2022 11:26 — forked from paulofreitas/AuthServiceProvider.php
Extending the default Eloquent User Provider (Laravel 5.4+)
<?php
namespace App\Providers;
use App\Auth\UserProvider;
use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider;
class AuthServiceProvider extends ServiceProvider
{
/**
@hrvoj3e
hrvoj3e / nginx-location-example.conf
Last active February 24, 2022 10:22
tusd subfolder deploy
location /my-subfolder/ {
# Forward incoming requests to local tusd instance
proxy_pass http://192.168.54.111:8472/;
proxy_redirect ~/files/(.*)$ $scheme://$host/my-subfolder/files/$1;
# Disable request and response buffering
proxy_request_buffering off;
proxy_buffering off;
proxy_http_version 1.1;
openapi: 3.0.2
info:
title: demo
version: 1.0.0
description: ''
paths:
/demo:
get:
parameters:
- in: query