Skip to content

Instantly share code, notes, and snippets.

View mrcrilly's full-sized avatar

Michael Crilly mrcrilly

View GitHub Profile
@mrcrilly
mrcrilly / occulta_navis_alpha_heron.eft
Created April 22, 2024 11:38
EVE Online Heron Alpha Fit for Exploration
[Heron, Heron ON Alpha Scout/Explorer]
Type-D Restrained Inertial Stabilizers
Type-D Restrained Inertial Stabilizers
5MN Microwarpdrive I
Relic Analyzer I
Data Analyzer I
Cargo Scanner I
[Empty Med slot]
@mrcrilly
mrcrilly / SFE.md
Last active February 23, 2024 01:14
Simple First Engineering

Always Start Simple (ASS)

This is why I'm grumpy and sulking in the (metaverse) corner:

  1. Businesses solve problems via solutions they sell on the open market
  2. When it's a software based solution, it's really easy to get things right
  3. Everything is simple, however everyone overcomplicates it
  4. It's entirely possible businesses choose certain technology stacks because they feel that by not choosing them they're unable to attract the latest and greatest talent
  5. And the labour market also feels that by not choosing to learn and understand the latest and greatest technologies, they become unhirable
@mrcrilly
mrcrilly / gin_jwt_middleware.go
Last active February 23, 2024 01:13
Gin JWT Middleware (Example)
package main
import (
"errors"
"net/http"
"strconv"
"strings"
"time"
"github.com/dgrijalva/jwt-go"
@mrcrilly
mrcrilly / example.html.j2
Last active December 14, 2023 23:25
Basic Pythn/Flask/Jinja2 for-loop
# templates/product.html
# change the HTML to suit your needs
<h1>{{ product.name }}</h1>
<p>{{ product.description }}</p>
<p>Price: ${{ product.price }}</p>
@mrcrilly
mrcrilly / test.py
Created December 7, 2023 10:46
Testing
def main():
print("Hello, world!")
main()
@mrcrilly
mrcrilly / iac_semver.md
Last active December 6, 2023 16:26
A better way of version controlling IAC

Semantic Versioning for IAC - iacver

When it comes to Infrastructure As Code, the software versioning system known as Semantic Versioning (semver.org) works from an API perspective but falls short elsewhere.

In short a semver is broken down into three "octets" and optional, additional information tagged to the end. Here are a few examples: v1.0.1, v3.1.1, v1.15.0-4. Each of these is a valid semver.

If we take the first example - v1.0.1 - and change the first octet, 1, to 2, we're saying the following:

There has been a change to this code and that change is not compatible with how you're using v1.0.1. The change is a breaking change. You should take care to introduce version v2.0.0 into your code or your environment.

Linux Backup Solutions

I've been looking for the best Linux backup system, and also reading lots of HN comments.

Instead of putting pros and cons of every backup system I'll just list some deal-breakers which would disqualify them.

Also I would like that you, the HN community, would add more deal breakers for these or other backup systems if you know some more and at the same time, if you have data to disprove some of the deal-breakers listed here (benchmarks, info about something being true for older releases but is fixed on newer releases), please share it so that I can edit this list accordingly.

Bacula (from the Why section on Burp)

  • Too complex to configure
  • Stores catalog separate from backups, need to backup catalog
@mrcrilly
mrcrilly / solution.md
Last active April 17, 2023 11:46
libc6-dev : Depends: libc6 (= 2.35-0ubuntu3) but 2.35-0ubuntu3.1 is to be installed

This is a small guide on resolving an issue I was having that prevented me from installing libc6-dev. The issue I was having was as such:

libc6-dev : Depends: libc6 (= 2.35-0ubuntu3) but 2.35-0ubuntu3.1 is to be installed

The libc6-dev package wants to install version 2.35-0ubuntu3, which is (very slightly) "older" than the libc6 package I have installed at version 2.35-0ubuntu3.1 (notice the .1). This basically prevents me from installing libc6-dev which in turn prevents me from installing build-essential. You need build-essential to do a lot of development work, such as compiling C code.

Here is the process I went through, from discovering the problem to solving it, but let's start with the solution straight up.

@mrcrilly
mrcrilly / errors.txt
Created March 20, 2023 04:35
Gayan's TF
$ terraform init
Initializing the backend...
There are some problems with the configuration, described below.
The Terraform configuration must be valid before initialization so that
Terraform can determine which modules and providers need to be installed.
│ Error: Duplicate resource "aws_lb_target_group" configuration
@mrcrilly
mrcrilly / map.md
Created January 17, 2023 23:19
Roadmap

Basics

  1. Hardware Basics
  2. Operating Systems
  3. Networking
  4. Virtualisation
  5. System Administration
  6. Database Basics
  7. Cloud Computing
  8. Capstone Project (WordPress)