2025-08-15 16:36:13 -07:00
2025-08-14 20:00:06 -07:00
2025-08-14 19:30:32 -07:00
2025-08-14 19:58:53 -07:00
2025-08-14 19:58:53 -07:00
2025-08-02 17:04:04 -07:00
2025-08-02 17:04:04 -07:00
2025-08-02 15:02:57 -07:00
2025-08-14 19:25:53 -07:00
2025-08-15 16:36:13 -07:00
2025-08-14 20:19:11 -07:00

noteserver

Server for Notes

Usage

This program is intended for and tested on Linux, but may work on other systems. The server, being a simple binary, can be deployed easily in several ways. The recommended method is using Docker. Simply run docker-deploy.sh after initializing the database. This will build the docker image and run the server on port 3002.

git clone https://git.miningtcup.me/MiningTcup/noteserver.git
cd noteserver
sh reload.sh
sh docker-deploy.sh

After starting the Docker container and checking that it's up, you should use nginx or another reverse proxy to enable HTTPS.

server
{
	location / {
		proxy_pass http://127.0.0.1:3002;
		proxy_set_header Host $host;
		proxy_set_header X-Real-IP $remote_addr;
		proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
		proxy_set_header X-Forwarded-Proto $scheme;
	}

	server_name notes.miningtcup.me; # managed by Certbot

	listen 443 ssl; # managed by Certbot
	listen [::]:443 ssl; # managed by Certbot
	ssl_certificate /etc/letsencrypt/live/miningtcup.me/fullchain.pem; # managed by Certbot
	ssl_certificate_key /etc/letsencrypt/live/miningtcup.me/privkey.pem; # managed by Certbot
	include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
	ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
Description
Simple server written in Go for my Notes.
Readme AGPL-3.0 17 MiB
Languages
Go 89.7%
Shell 7.6%
Dockerfile 2.7%