Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠

Cosmic Sound uhlhosting

🏠
View GitHub Profile
@uhlhosting
uhlhosting / btcpayserver_install_env.sh
Created Feb 14, 2021 — forked from rockstardev/btcpayserver_install_env.sh
Setting up BTCPayServer development environment on Linux (Ubuntu)
View btcpayserver_install_env.sh
# Installing prerequisites for BTCPayServer development on Ubuntu
# Install .NET Core SDK 2.2
# https://dotnet.microsoft.com/learn/dotnet/hello-world-tutorial/install?initial-os=linux
wget -q https://packages.microsoft.com/config/ubuntu/18.04/packages-microsoft-prod.deb -O packages-microsoft-prod.deb
sudo dpkg -i packages-microsoft-prod.deb
sudo add-apt-repository universe
@uhlhosting
uhlhosting / alfio
Created Nov 7, 2020 — forked from ieugen/alfio
alf.io debian deployment
View alfio
/etc/default/alfio
----
JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-amd64/jre
MODE=service
#PORT=9001
JAVA_OPTS="-Ddatasource.driver=org.postgresql.Driver -Ddatasource.url=jdbc:postgresql://localhost:5433/alfio -Ddatasource.username=alfio -Ddatasource.password=secret -Ddatasource.dialect=PGSQL -Ddatasource.validationQuery='SELECT 1'"
View Fedora Dynamic Message of the day - motd
#!/bin/bash
# Installation:
#
# 1. vim /etc/ssh/sshd_config
# PrintMotd no
#
# 2. vim /etc/pam.d/login
# # session optional pam_motd.so
#
View keybase.md

Keybase proof

I hereby claim:

  • I am uhlhosting on github.
  • I am kosmos (https://keybase.io/kosmos) on keybase.
  • I have a public key ASCST8u0PSOrtvxm7PYk_ke531LkuCyRhAykiIl1hJ1PnAo

To claim this, I am signing this object:

@uhlhosting
uhlhosting / nginxproxy.md
Created Sep 3, 2018 — forked from soheilhy/nginxproxy.md
How to proxy web apps using nginx?
View nginxproxy.md

Virtual Hosts on nginx (CSC309)

When hosting our web applications, we often have one public IP address (i.e., an IP address visible to the outside world) using which we want to host multiple web apps. For example, one may wants to host three different web apps respectively for example1.com, example2.com, and example1.com/images on the same machine using a single IP address.

How can we do that? Well, the good news is Internet browsers

@uhlhosting
uhlhosting / wp-config.php
Created Mar 28, 2018 — forked from MattWilcox/wp-config.php
Bits to add to wp-config.php to make things sane when developing in a real development system (local > stage > live) instead of developing directly on a live server. Which is what WP is set up to do and which is ridiculous.
View wp-config.php
/* Lets not rely on paths in the database, they can be very wrong when moving between dev/stage/live environments */
/* The following two variables are backward to my thinking, but hey, what ya gonna do? */
define('WP_HOME', 'http://' . $_SERVER['HTTP_HOST'] . ''); // This is NOT the 'wordpress admin area' home, but the site's home
define('WP_SITEURL', 'http://' . $_SERVER['HTTP_HOST'] . '/SECRETDIRECTORY'); // This isn't the site's URL but the WordPress admin area URL
/* MySQL settings */
switch($_SERVER['SERVER_NAME']){
// Your local machine's settings
case 'mysite.local':
define('DB_NAME', 'dev_mysite');
@uhlhosting
uhlhosting / debian_upgrade.yml
Created Mar 5, 2018 — forked from maethor/debian_upgrade.yml
Ansible playbook to update and upgrade Debian hosts
View debian_upgrade.yml
---
- hosts: all
sudo: yes
tasks:
- name: Update packages list
apt: update_cache=yes
when: ansible_os_family == 'Debian'
- name: List packages to upgrade (1/2)
View gist:89c29d8d6cae838ed8ffecc9bd91fc70

Installing Kubernetes on Proxox

For this example i shall be using a dedicated server from Hertzner.https://www.hetzner.de/en/. A shout out to hetzner if your looking for cheap and beefy dedicated hosting then these guys are your best bet.

Setting up the Hertzer server

This guide assumes your server has Debian 8 (Jessie installed)

Config when tested

@uhlhosting
uhlhosting / dynmotd
Created Jul 6, 2017 — forked from cha55son/dynmotd
RHEL (Centos/Fedora) dynamic motd
View dynmotd
#!/bin/bash
# Installation:
#
# 1. vim /etc/ssh/sshd_config
# PrintMotd no
#
# 2. vim /etc/pam.d/login
# # session optional pam_motd.so
#