How to build home server
사실 홈 서버를 구축해보고 싶다는 생각은 이전부터 했으나 실행을 계속 미루다가 최근에 다시 도전하게 되었다.
홈 서버를 통해서 일단 내가 하고자 하는 것은 파일 공유, 영화 및 애니 스트리밍 그리고 토렌트다.
막힌 부분이 있어 조금씩 바뀔 수도 있다.
The list that I used
- Ubuntu 22 LTS
- cpu : fx8300
- ram : 16GB
- docker (portainer) / none docker
- firewall
- netfilter / iptables / ufw
- fail2ban
- ddclient
- Google OTP
- cloud
- nextCloud (php, nginx, mariadb) / snap nextCloud
- torrnet
- qbittorrent-nox / transmission - have to use nginx??
- streaming
- yet chosen
- blog
- wordpress
Order
- Install Ubuntu
sudo apt-get update
sudo apt-get upgrade
sudo lshw -c network
vi /etc/netplan/00-installer-config.yaml
sudo netplan apply
sudo reboot now
- Disable UFW & Enable iptables
- to use iptables, you have to disable or uninstall UFW and firewalld
sudo ufw reset
sudo ufw disable
sudo service iptables status
sudo service iptables start
- 3rd day
- having prob within firewall and port
- allowed 80, 443, 8080, 8888 port within NAT and server but only connected ssh
- will keep on working to solve this prob;
- solved : even though port was opened though router and server os, an application that uses port must be installed….
- 4th day
- considering whether install npm and db linked or not
- even considering linking db to other services or not
- 5th day
- installing
nginx proxy manager
and redirect when subdomains are in
- installing
- 6th day
- compose heimdall docker through docker-compose
-
version: "2.1" services: heimdall: image: lscr.io/linuxserver/heimdall container_name: heimdall environment: - PUID=1000 - PGID=1000 - TZ=Asia/Seoul volumes: - /data/heimdall/config:/config ports: - 8080:80 - 8443:443 restart: unless-stopped
- 7th day
- compose
nginx proxy manager
through docker-compose -
version: '3' services: app: image: 'jc21/nginx-proxy-manager:latest' restart: unless-stopped ports: - '80:80' - '81:81' - '443:443' volumes: - ./data:/data - ./letsencrypt:/etc/letsencrypt
docker-compose up -d
- compose