-1

I am attempting to log in to an enterprise dashboard, but I'm encountering an error message: "We are currently unable to log you in."

Within the terminal, the following information is displayed:

9:43:27 AM [vite] http proxy error at /xqwapi/login:
Error: connect ECONNREFUSED 0.0.0.0:8021
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1142:16)
9:43:36 AM [vite] http proxy error at /xqwapi/login:
Error: connect ECONNREFUSED 0.0.0.0:8021
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1142:16) (x2)
9:43:38 AM [vite] http proxy error at /xqwapi/login:
Error: connect ECONNREFUSED 0.0.0.0:8021
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1142:16) (x3)
9:45:17 AM [vite] http proxy error at /xqwapi/login:
Error: connect ECONNREFUSED 0.0.0.0:8021
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1142:16) (x4)
9:48:50 AM [vite] http proxy error at /xqwapi/login:
Error: connect ECONNREFUSED 0.0.0.0:8021
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1142:16) (x5)

I had successfully accessed the dashboard before but now I am getting this error. What do I need to do? Thank you!

These are the running ports and I don't know what to do. Ports

This is my index.js

import express from 'express';
import path from 'path';
import morgan from 'morgan';

const app = express();

const index = path.join(path.resolve('./ui/dist'), 'index.html');

app.set('trust proxy', true);
app.set('view cache', true);
app.use(express.static(path.join(path.resolve('./ui/dist'))));
app.use(morgan('common'));

app.get('*', (req, res) => {
  res.sendFile(index);
});

const PORT = process.env.VITE_EXPRESS_PORT || 9000;
app.listen(PORT, () => {
  console.log(`Listening to port ${PORT}`); // eslint-disable-line no-console
});
  • 1
    Does this answer your question? [What is the difference between 0.0.0.0, 127.0.0.1 and localhost?](https://stackoverflow.com/questions/20778771/what-is-the-difference-between-0-0-0-0-127-0-0-1-and-localhost) – tripleee Aug 16 '23 at 04:36
  • Hi guys, already solved this. I just modified my code in terminal from export FLASK_APP=backend/app.py && flask run to export FLASK_APP=backend/app.py && flask run --port 8021 --host 0.0.0.0 – Arjay Rosel Aug 29 '23 at 02:02

0 Answers0