back/config: replace localhost with 127.0.0.1

This commit is contained in:
Alice Gaudon 2021-11-28 21:24:51 +01:00
parent ae603362e9
commit 366e48757e
6 changed files with 7 additions and 8 deletions

View File

@ -4,8 +4,8 @@
app: { app: {
listen_addr: '127.0.0.1', listen_addr: '127.0.0.1',
port: 4899, port: 4899,
public_url: "http://localhost:4899", public_url: "http://127.0.0.1:4899",
public_websocket_url: "ws://localhost:4899", public_websocket_url: "ws://127.0.0.1:4899",
name: 'Example App', name: 'Example App',
contact_email: 'contact@example.net', contact_email: 'contact@example.net',
display_email_warning: true, display_email_warning: true,
@ -36,7 +36,7 @@
}, },
mysql: { mysql: {
connectionLimit: 10, connectionLimit: 10,
host: "localhost", host: "127.0.0.1",
user: "root", user: "root",
password: "", password: "",
database: "swaf", database: "swaf",

View File

@ -3,7 +3,7 @@
approval_mode: true, approval_mode: true,
}, },
mysql: { mysql: {
host: "localhost", host: "127.0.0.1",
user: "root", user: "root",
password: "", password: "",
database: "swaf_test", database: "swaf_test",

View File

@ -16,6 +16,5 @@ module.exports = {
'**/test/**/*.test.ts' '**/test/**/*.test.ts'
], ],
testEnvironment: 'node', testEnvironment: 'node',
testTimeout: 60000,
resolver: "jest-ts-webcompat-resolver", resolver: "jest-ts-webcompat-resolver",
}; };

View File

@ -19,7 +19,7 @@
"compile": "yarn clean && yarn prepare-sources && tsc --build", "compile": "yarn clean && yarn prepare-sources && tsc --build",
"build": "yarn compile && node . pre-compile-views && node scripts/dist.js", "build": "yarn compile && node . pre-compile-views && node scripts/dist.js",
"build-production": "NODE_ENV=production yarn build", "build-production": "NODE_ENV=production yarn build",
"dev": "yarn compile && concurrently -k -n \"Maildev,Typescript,ViewPreCompile,Node\" -p \"[{name}]\" -c \"yellow,blue,red,green\" \"maildev\" \"tsc --build --watch --preserveWatchOutput\" \"nodemon -i public -i intermediates -- pre-compile-views --watch\" \"nodemon -i public -i intermediates\"", "dev": "yarn compile && concurrently -k -n \"Maildev,Typescript,ViewPreCompile,Node\" -p \"[{name}]\" -c \"yellow,blue,red,green\" \"maildev --ip 127.0.0.1\" \"tsc --build --watch --preserveWatchOutput\" \"nodemon -i public -i intermediates -- pre-compile-views --watch\" \"nodemon -i public -i intermediates\"",
"lint": "eslint .", "lint": "eslint .",
"release": "yarn build && yarn lint && yarn test && cd dist && yarn publish" "release": "yarn build && yarn lint && yarn test && cd dist && yarn publish"
}, },

View File

@ -21,7 +21,7 @@ export default class ExpressAppComponent extends ApplicationComponent {
public async start(app: Express): Promise<void> { public async start(app: Express): Promise<void> {
this.server = app.listen(this.port, this.addr, () => { this.server = app.listen(this.port, this.addr, () => {
logger.info(`Web server running on http://${this.addr}:${this.port}.`); logger.info(`Web server running on http://${this.addr}:${this.port}`);
}); });
// Proxy // Proxy

View File

@ -1,7 +1,7 @@
import MailDev, {Mail} from "maildev"; import MailDev, {Mail} from "maildev";
export const MAIL_SERVER = new MailDev({ export const MAIL_SERVER = new MailDev({
ip: 'localhost', ip: '127.0.0.1',
}); });
export async function setupMailServer(): Promise<void> { export async function setupMailServer(): Promise<void> {