Skip to content

Instantly share code, notes, and snippets.

View JWT_FOR_DUMMIES.md

Login with username/email and password:


$ curl --silent -d '{"email":"user@example.com","password":"SUPERSECRETPASSWORD"}' -H "Content-Type: application/json" -X POST http://vue-spa-laravel-vue-spa.localhost/api/login | jq '.'
{
  "token": "REDACTED",
 "token_type": "bearer",
@timogoosen
timogoosen / gist:8a13501aa8e4fed5e8f4daaa8949ba35
Created Aug 30, 2022
Setup php7.4 Mac OSX alongside php7.3
View gist:8a13501aa8e4fed5e8f4daaa8949ba35
brew install shivammathur/php/php@7.4
export PATH="/opt/homebrew/opt/php@7.4/bin:$PATH"
pecl install igbinary
pecl install redis
pecl install imagick
brew services restart php@7.4
curl -sS https://getcomposer.org/installer | php -- --version=1.10.16
sudo mkdir -p /usr/local/bin
@timogoosen
timogoosen / get-uptime-check-ips.py
Created Jun 17, 2022
List Google Cloud Uptime Check IPs
View get-uptime-check-ips.py
#/usr/bin/env python3
from google.cloud import monitoring_v3
client = monitoring_v3.UptimeCheckServiceClient()
ips = client.list_uptime_check_ips()
for ip in ips:
View gist:32e7c0eb393c111f194c512c1199d495
Interesting commands:
```
terraform state list
```
See interpolated values and local values:
View docker-compose.yml
version: '3.6'
services:
app:
build:
context: .
dockerfile: deployment/dockerfile-with-non-standard-name # This points to the dockerfile if the name isnt "Dockerfile"
args:
- VERSION=1.0.0
environment:
@timogoosen
timogoosen / docker-compose.yml
Created Oct 20, 2018
Added Elasticsearch plus a volume for Elasticsearch's data. The normal Elasticsearch config is for an ephermeral Elasticsearch setup.
View docker-compose.yml
version: "3"
services:
mariadb:
image: wodby/mariadb:$MARIADB_TAG
container_name: "${PROJECT_NAME}_mariadb"
stop_grace_period: 30s
environment:
MYSQL_ROOT_PASSWORD: $DB_ROOT_PASSWORD
MYSQL_DATABASE: $DB_NAME
@timogoosen
timogoosen / docker-compose.yml
Created Oct 20, 2018
Added Elasticsearch plus a volume for Elasticsearch's data. The normal Elasticsearch config is for an ephermeral Elasticsearch setup.
View docker-compose.yml
version: "3"
services:
mariadb:
image: wodby/mariadb:$MARIADB_TAG
container_name: "${PROJECT_NAME}_mariadb"
stop_grace_period: 30s
environment:
MYSQL_ROOT_PASSWORD: $DB_ROOT_PASSWORD
MYSQL_DATABASE: $DB_NAME
View docker-compose.yml
version: "3"
services:
mariadb:
image: wodby/mariadb:$MARIADB_TAG
container_name: "${PROJECT_NAME}_mariadb"
stop_grace_period: 30s
environment:
MYSQL_ROOT_PASSWORD: $DB_ROOT_PASSWORD
MYSQL_DATABASE: $DB_NAME
View docker-compose.yml
version: "2"
services:
mariadb:
image: wodby/mariadb:$MARIADB_TAG
container_name: "${PROJECT_NAME}_mariadb"
stop_grace_period: 30s
environment:
MYSQL_ROOT_PASSWORD: $DB_ROOT_PASSWORD
MYSQL_DATABASE: $DB_NAME
View docker-compose.yml
version: "2"
services:
mariadb:
image: wodby/mariadb:$MARIADB_TAG
container_name: "${PROJECT_NAME}_mariadb"
stop_grace_period: 30s
environment:
MYSQL_ROOT_PASSWORD: $DB_ROOT_PASSWORD
MYSQL_DATABASE: $DB_NAME