From 940ab07d35e739c6479da9f312c6ee760e107309 Mon Sep 17 00:00:00 2001 From: Pitu Date: Fri, 18 Jun 2021 01:45:19 +0900 Subject: [PATCH] feat: prevent running without a domain --- src/api/structures/Server.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/api/structures/Server.js b/src/api/structures/Server.js index 0ee3ea3..f584fe8 100644 --- a/src/api/structures/Server.js +++ b/src/api/structures/Server.js @@ -5,6 +5,11 @@ if (!process.env.SERVER_PORT) { process.exit(0); } +if (!process.env.DOMAIN) { + console.log('You failed to provide a domain for your instance. Edit the .env file manually and fix it.'); + process.exit(0); +} + const { loadNuxt, build } = require('nuxt'); const express = require('express'); const helmet = require('helmet');