Skip to content

Instantly share code, notes, and snippets.

View evertramos's full-sized avatar
🐳
Automating things!

Evert R. evertramos

🐳
Automating things!
View GitHub Profile

PostgreSQL

Backup

docker exec -u <your_postgres_user> <postgres_container_name> pg_dump -Fc <database_name_here> > db.dump

Restore

docker exec -i -u   pg_restore -C -d  &lt; db.dump
@evertramos
evertramos / Filter.php
Created July 25, 2019 14:41 — forked from szabomikierno/Filter.php
Filter trait for any Laravel Model
<?php
namespace App\Core\Model;
/**
* FILTER QUERY PARAMS
*
* @param (boolean) active
* The returned resources active (deleted_at) status
@evertramos
evertramos / ext.txt
Created February 3, 2020 18:06 — forked from chronon/ext.txt
List of docker-php-ext-install extension names
Possible values for ext-name:
bcmath
bz2
calendar
ctype
curl
dba
dom
enchant
@evertramos
evertramos / bash-colors.md
Created January 28, 2022 12:19 — forked from iamnewton/bash-colors.md
The entire table of ANSI color codes.

Regular Colors

Value Color
\e[0;30m Black
\e[0;31m Red
\e[0;32m Green
\e[0;33m Yellow
\e[0;34m Blue
\e[0;35m Purple
@evertramos
evertramos / CaddyController.php
Created February 5, 2022 11:55 — forked from gilbitron/CaddyController.php
Enabling HTTPS (SSL) for Laravel Sail using Caddy
<?php
# app/Http/Controllers/CaddyController.php
namespace App\Http\Controllers;
use App\Store;
use Illuminate\Http\Request;
class CaddyController extends Controller
{