Skip to content

EDM115/website

Repository files navigation

EDM115/website

Basically my website, hosted at edm115.dev (edm115.eu.org is a backup (also available at old.edm115.dev), real-time preview of the latest commit at edm115.netlify.app)

DeepSource

Minimal repro

git clone https://github.com/EDM115/website.git && cd website
pnpm i
pnpm dev
pnpm lint:fix
pnpm build
pnpm preview:ssr

pnpm generate
pnpm preview:ssg

Old stuff


NGINX setup (on my VPS)

(supposing that the repo is at /home/edm115/website and that it is built)

sudo find /home/edm115/website/dist -type d -exec chmod 755 {} \;
sudo find /home/edm115/website/dist -type f -exec chmod 644 {} \;
sudo chmod -R 755 /home/edm115/website/dist
sudo chmod -R 755 /home/edm115/website

In /etc/nginx/sites-available/default :

server {
    listen 443 ssl;
    listen [::]:443 ssl;
    # Only if you have a certificate
    ssl_certificate /home/edm115/.secure/cloudflare-origin-server.pem;
    ssl_certificate_key /home/edm115/.secure/cloudflare-origin-server.key;

    listen 80;
    listen [::]:80;

    include /etc/nginx/mime.types;
    default_type application/octet-stream;

    location / {
        # Redirects to handle the hosted bots
        # Hackish way to get the subdomains working with one IP
        # Don't forget to also run sudo chmod -R 755 /home/edm115/.secure
        if ($host ~* ^jm-vps) {
            proxy_pass http://127.0.0.1:9898;
            break;
        }

        if ($host ~* ^dicewizard-vps) {
            proxy_pass http://127.0.0.1:8686;
            break;
        }

        if ($host ~* ^edm115-discord-vps) {
            proxy_pass http://127.0.0.1:8888;
            break;
        }

        if ($host ~* ^logs-vps) {
            proxy_pass http://127.0.0.1:10000;
            break;
        }

        # No longer hosted
        if ($host ~* ^senescalade) {
            return 301 https://github.com/EDM115-org/Senescalade;
        }

        # Also pass URL params
        if ($host ~* ^next) {
            return 301 https://edm115.netlify.app$request_uri;
        }

        # Global else case for raw requests to the IP, when the website was hosted elsewhere
        # return 301 https://edm115.dev;

        # When using npm run serve
        # return proxy_pass http://127.0.0.1:10101;

        root /home/edm115/website/dist;
        index index.html;
        try_files $uri $uri/ /index.html;
    }
}

About

Basically my website, made with Vue and Vuetify

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Contributors 8