Skip to content

Instantly share code, notes, and snippets.

# Laravel queue worker using systemd
# ----------------------------------
#
# /lib/systemd/system/queue.service
#
# run this command to enable service:
# systemctl enable queue.service
[Unit]
Description=Laravel queue worker
; supervisor config file
[unix_http_server]
file=/var/run/supervisor.sock ; (the path to the socket file)
chmod=0700 ; sockef file mode (default 0700)
[supervisord]
logfile=/var/log/supervisor/supervisord.log ; (main log file;default $CWD/supervisord.log)
pidfile=/var/run/supervisord.pid ; (supervisord pidfile;default supervisord.pid)
childlogdir=/var/log/supervisor ; ('AUTO' child log dir, default $TEMP)
@erycson
erycson / Protector.js
Last active July 1, 2020 10:00
Web Cryptography API + ECDH + AES
class Protector {
ab2str(buffer) {
return new TextDecoder().decode(buffer);
}
str2ab(text) {
return new TextEncoder().encode(text);
}
generateIv() {
@erycson
erycson / Caddyfile
Last active August 7, 2019 14:36 — forked from paulredmond/Dockerfile
A Dockerfile for a Laravel PHP Application with Caddy Server
0.0.0.0
root /srv/app/public
gzip
fastcgi / 127.0.0.1:9000 php
rewrite {
regexp .*
ext /
to /index.php?{query}
}
@erycson
erycson / progressbar-page-load.html
Created June 21, 2018 19:47
Progresso de carregamento da página
<!DOCTYPE html>
<html>
<head>
<link href="http://ricostacruz.com/nprogress/nprogress.css?t=4" rel="stylesheet" />
<script src="http://ricostacruz.com/nprogress/nprogress.js?t=4"></script>
<script>
NProgress.start();
let current = 2;
let total = document.querySelectorAll('script, img, link').length;
--
-- Sistema de Atualização do Ranking Geral para o Gunbound WC v440 GBS
-- Copyright (C) 2016 Érycson Nóbrega <egdn2004@gmail.com>
--
-- 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 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
--
-- Sistema de Atualização do Ranking Semanal para o Gunbound WC v440 GBS
-- Copyright (C) 2016 Érycson Nóbrega <egdn2004@gmail.com>
--
-- 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 3 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
@erycson
erycson / LLtoUTM.cs
Created February 18, 2016 16:13
Converting latitude and longitude to UTM using ProjNet
/*
* LL to UTM Converter
* Copyright (C) 2016 Érycson Nóbrega <egdn2004@gmail.com>
*
* 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 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
/*
* IndoorAtlas Unity3D Client
* Copyright (C) 2016 Érycson Nóbrega <egdn2004@gmail.com>
*
* 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 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,