Category: DevOps
-
GitHub Actions – No .git folder fix for Docker builds
Add `context: .` to `docker/build-push-action` to fix the no `.git` folder issue.
-
Swapping on Ubuntu 20.04 Summary (via DigitalOcean)
Thought this was useful to note, but these are just the commands from this article from DigitalOcean about enabling swap without reading everything (basically a tl;dr): https://www.digitalocean.com/community/tutorials/how-to-add-swap-space-on-ubuntu-20-04 Checking swap: Enabling (temp): Enabling (perm): Configuring (in /etc/sysctl.conf): Set to minimize swap on VPS to reduce host hardware impact (values between 0-100, 0 being reduced swapping, 100…
-
Laravel – Enable SSL on MySQL/MariaDB Connections
In database.php modify to have these lines, yours might not have it already included: ‘sslmode’ => env(‘DB_SSLMODE’, ‘prefer’),’options’ => extension_loaded(‘pdo_mysql’) ? array_filter([ PDO::MYSQL_ATTR_SSL_CA => env(‘MYSQL_ATTR_SSL_CA’) !== null ? base_path(env(‘MYSQL_ATTR_SSL_CA’)) : env(‘MYSQL_ATTR_SSL_CA’),]) : [], Then, in .env you must add two additional keys: MYSQL_ATTR_SSL_CA=ca.crt Where this file is inside the current project directory, you can make…
-
OpenSSL Reference Sheet
I’ve been exploring OpenSSL and other encryption stuff and making a Certificate Authority etc. etc.Here’s some helpful commands that I’ve been referencing and some options that I thought would be useful. This reference sheet will be using RSA and SHA algorithms and doesn’t cover elliptic curve or other methods. We will also be choosing a…
-
Laravel – Fix 419 Page Expired with config:cache
I’m working on a project that uses Laravel and sessions for login and other forms. I’ve encountered an issue where I would encounter a 419 Page Expired error when running my project on a local development environment. The solution ended up being the need to manually cache the config with: php artisan config:cache Whenever you…