Skip to content

Instantly share code, notes, and snippets.

View beevk's full-sized avatar

Bivek Singh beevk

View GitHub Profile
@beevk
beevk / ghost-compose.yml
Last active April 7, 2024 18:12
Traefik + Ghost + Cloudflare
# docker compose for Ghost
networks:
proxy:
name: web
external: true
services:
ghost:
image: beevk/ghost-s3:v1.0.0
restart: always
@beevk
beevk / mysql-docker.sh
Created March 15, 2024 13:15 — forked from spalladino/mysql-docker.sh
Backup and restore a mysql database from a running Docker mysql container
# Backup
docker exec CONTAINER /usr/bin/mysqldump -u root --password=root DATABASE > backup.sql
# Restore
cat backup.sql | docker exec -i CONTAINER /usr/bin/mysql -u root --password=root DATABASE
@beevk
beevk / backup.sh
Created March 14, 2024 18:02
backup and restore DB running inside container
#!/bin/bash
# Function to display usage information
usage() {
echo "Usage: $0 <container_name>"
echo " - container_name: Name of the Docker container running MySQL"
exit 1
}
container_name="$1"
@beevk
beevk / multitab-code-editor-html-snippet.html
Last active March 18, 2024 08:51
Ghost snippet for multi tab code editor - uses Tailwind for styling
<div class="multitab-code-editor">
<div class="border-b border-gray-200 dark:border-gray-700">
<nav class="flex space-x-2" aria-label="Tabs" role="tablist">
<button type="button" class="tab-title" id="tab-1" data-hs-tab="#tab-1" aria-controls="tab-1" role="tab">
JavaScript
</button>
<button type="button" class="tab-title" id="tab-2" data-hs-tab="#tab-2" aria-controls="tab-2" role="tab">
TypeScript
</button>
<button type="button" class="tab-title" id="tab-3" data-hs-tab="#tab-3" aria-controls="tab-3" role="tab">
@beevk
beevk / pdf-content.txt
Last active November 10, 2023 11:56
Tech by Hexagon - PDF Content
----------------------------------------------------------------
Page 1
----------------------------------------------------------------
"Tech meets Trend: Transforming Ideas into Impact"
Tech by Hexagon Labs
----------------------------------------------------------------
@beevk
beevk / wireguard-multiple-users.md
Last active June 6, 2023 11:59 — forked from qdm12/README.md
Wireguard and iptables restrictions for multiple users

Wireguard and iptables restrictions for multiple users

If you don't know what Wireguard is, well, you should. It's fast, easy to setup and highly configurable. We will configure Wireguard for multiple users with various restrictions using iptables.

Assumptions

This should fit most setups (not mine though 😉)

javascript: (function () {
function AddTaskId() {
var project = document.getElementsByClassName('TopbarPageHeaderStructure-title')[0].textContent;
project = project.replace("BCHU ", "")
.replace("Runway", "STORE")
.toUpperCase()
.replace("IOS APP", "iOS");
var d = new Date();
var month = ('0' + (d.getMonth() + 1)).slice(-2);
var day = ('0' + d.getDate()).slice(-2);