Skip to content

Instantly share code, notes, and snippets.

View josephbolus's full-sized avatar

Joseph Bolus josephbolus

View GitHub Profile

Make it real

Ideas are cheap. Make a prototype, sketch a CLI session, draw a wireframe. Discuss around concrete examples, not hand-waving abstractions. Don't say you did something, provide a URL that proves it.

Ship it

Nothing is real until it's being used by a real user. This doesn't mean you make a prototype in the morning and blog about it in the evening. It means you find one person you believe your product will help and try to get them to use it.

Do it with style

@josephbolus
josephbolus / npm-template.md
Created October 11, 2023 20:24 — forked from scyto/npm-template.md
Nginx Proxy Manager swarm template

Description

This template runs my experimental NPM service as part of evaluating if i should stop using my hand crafted nginx reverse proxy. Note change your passwords and don't use the examples bellow :-) )

State Considerations for SWARM

This container has a database, as such I store the data on the gluster volume. I am currenlty using a mount point to store the voume data on glusterfs. I restrict to 1 instance of each container to avoid database corruption from having two instances. Change example usernames and passwords as needed. leave hostname as db (name resolution works fine using the method)

@josephbolus
josephbolus / ssh-key-for-ansible-playbook.md
Created May 2, 2023 19:16 — forked from OlegGorj/ssh-key-for-ansible-playbook.md
Specifying ssh key in ansible playbook file

The variable name is ansible_ssh_private_key_file .

One should set it at 'vars' level:

  • in the inventory file:
myHost ansible_ssh_private_key_file=~/.ssh/mykey1.pem
myOtherHost ansible_ssh_private_key_file=~/.ssh/mykey2.pem
@josephbolus
josephbolus / d8-drushless-revert.sh
Created March 1, 2023 21:30 — forked from crittermike/d8-drushless-revert.sh
Revert configuration in Drupal 8 with Drush (without using Features)
drush cim -y --partial --source=modules/path/to/module/config/install/
@josephbolus
josephbolus / Readme.md
Created January 12, 2023 19:57 — forked from saniaky/Readme.md
Docker + nginx-proxy + let's encrypt + watchtower + fail2ban

Complete solution for websites hosting

This gist contains example of how you can configure nginx reverse-proxy with autmatic container discovery, SSL certificates generation (using Let's Encrypt) and auto updates.

Features:

  • Automatically detect new containers and reconfigure nginx reverse-proxy
  • Automatically generate/update SSL certificates for all specified containers.
  • Watch for new docker images and update them.
  • Ban bots and hackers who are trying to bruteforce your website or do anything suspicious.
@josephbolus
josephbolus / socks.txt
Last active November 14, 2023 18:00 — forked from jasdeepkhalsa/socks.txt
Configuring a SOCKS proxy server in Chrome
From: http://www.chromium.org/developers/design-documents/network-stack/socks-proxy
To configure chrome to proxy traffic through the SOCKS v5 proxy server myproxy:8080, launch chrome with these two command-line flags:
--proxy-server="socks5://myproxy:8080"
--host-resolver-rules="MAP * 0.0.0.0 , EXCLUDE myproxy"
The first thing to check when debugging is look at the Proxy tab on about:net-internals, and verify what the effective proxy settings are:
chrome://net-internals/#proxy
@josephbolus
josephbolus / Caddy.env
Created July 23, 2022 06:44 — forked from crazy-max/Caddy.env
Proxmox web interface through Caddy as reverse proxy with Let's Encrypt
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_HOSTED_ZONE_ID=
@josephbolus
josephbolus / Caddyfile
Created July 22, 2022 05:15 — forked from dimasahmad/Caddyfile
Install Caddy 2 on Ubuntu
# Refer to the Caddy docs for more information:
# https://caddyserver.com/docs/caddyfile
:80
reverse_proxy 10.100.100.1:80
@josephbolus
josephbolus / default.conf
Created June 16, 2022 21:43 — forked from fmaul/default.conf
nginx config that uses the oauth2-proxy (via auth_request) to authenticate against gitlab and then proxies all requests to a backend service while setting the auth headers X-User and X-Email
server {
listen 80;
server_name localhost;
location /oauth2/ {
proxy_pass http://oauth-proxy:4180;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Scheme $scheme;
proxy_set_header X-Auth-Request-Redirect $request_uri;
@josephbolus
josephbolus / The Technical Interview Cheat Sheet.md
Created March 20, 2021 16:23 — forked from tsiege/The Technical Interview Cheat Sheet.md
This is my technical interview cheat sheet. Feel free to fork it or do whatever you want with it. PLEASE let me know if there are any errors or if anything crucial is missing. I will add more links soon.

ANNOUNCEMENT

I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!






\