Server Installation

Installation guide for haircomb VPSes

Steps I did before this are:

  • chosen the 2GB ram server, latest ubuntu 24.04

  • bought the server, it started, they gave me the IP address

  • pointed the domain core.haircomber.com to the server IP address

Login to the server

  1. boot tails

  2. type ssh root@ip to the console

  3. become aware about the public key (to avoid logging into wrong server in the future)

  4. type password

  5. ubuntu console is presented

Initial things

  1. type apt-get update; apt-get upgrade to update the fresh server

  2. type apt-get install nginx to install basic web server

After this you go to http://core.haircomber.com and there is a message welcome to nginx

Cloning the repos from codeberg

git clone https://codeberg.org/watashi564/combdownloader-ng

git clone https://codeberg.org/watashi564/pricechart

git clone https://codeberg.org/watashi564/combswapui

git clone https://codeberg.org/watashi564/combfullui

Installing golang

sudo add-apt-repository ppa:longsleep/golang-backports

sudo apt update

apt-get install golang

I compile combfullui, combdownloader-ng, combswapui and pricechart using the usual way

Next I setup the nginx sites-available in /etc/nginx/sites-available

This is haircomb.org.conf:

server {

client_header_buffer_size 2000k;

large_client_header_buffers 16 2000k;

listen 443 ssl;

server_name core.haircomb.org www.core.haircomb.org;

ssl_certificate /etc/letsencrypt/live/core.haircomb.org-0001/fullchain.pem; # managed by Certbot

ssl_certificate_key /etc/letsencrypt/live/core.haircomb.org-0001/privkey.pem; # managed by Certbot

location / {

proxy_pass http://127.0.0.1:21212;

}

}

Generate dummy certs:

openssl req -x509 -nodes -newkey rsa:4096 -days 1 -keyout "/etc/letsencrypt/live/swap.haircomber.com-0001/privkey.pem" -out "/etc/letsencrypt/live/swap.haircomber.com-0001/fullchain.pem" -subj '/CN=localhost'

I setup configs, link sites-enabled to sites-available, restart nginx.

Install certbot

Install certbot using the digital ocean guide, then:

sudo certbot --nginx -d core.haircomber.com -d swap.haircomber.com

Start the usual services

I start them on screen screens.it

Last updated