Open Mel-louie opened 1 year ago
Our config is empty. In frontend/src/config/index.ts
, the const config
doesn't get the backendURL.
About the idea of using Dockerfile instead of Dockerfile.prod, if we disable hot-reload:
mdesfont/hot-reload
.Firefox can’t establish a connection to the server at ws://localhost/. [@vite-plugin-checker-runtime:1328:13](http://localhost:8000/@vite-plugin-checker-runtime)
I think the important part isvite-plugin-checker
. It's a checker that check several plugin of vite. And it check vite-hot-module-reload
. But since vite-hot-module-reload
is not enabled, it triggers an error. I can't manage to prevent this error. I'm not sure we can have vite-plugin-checker
without hot reload checks.
In vite.config.ts
, we have the possibility to comment:
checker({
vueTsc: true,
}),
and then, there is no error or hot reload. But I'm not sure it's a good idea. In fact, I don't really now. vite-plugin-checker
seems to be a great plugin, but maybe not that important at this point.
About the idea of using Dockerfile instead of Dockerfile.prod, if we disable hot-reload:
- I made a branch where it is disabled
mdesfont/hot-reload
.But, there is an error that appears:
Firefox can’t establish a connection to the server at ws://localhost/. [@vite-plugin-checker-runtime:1328:13](http://localhost:8000/@vite-plugin-checker-runtime)
I think the important part is
vite-plugin-checker
. It's a checker that check several plugin of vite. And it checkvite-hot-module-reload
. But sincevite-hot-module-reload
is not enabled, it triggers an error. I can't manage to prevent this error. I'm not sure we can havevite-plugin-checker
without hot reload checks. Invite.config.ts
, we have the possibility to comment:checker({ vueTsc: true, }),
and then, there is no error or hot reload. But I'm not sure it's a good idea. In fact, I don't really now.
vite-plugin-checker
seems to be a great plugin, but maybe not that important at this point.
It is not a problem to comment the checker. There is by default no type checking when using vite
, this is what this plugin does. If we merge a PR solving this issue at the very end (before the correction), it is not an issue.
I suppose it comes from the FortyTwo.vue component, but not really sure... So the problem is: When you launch ft_transcendence with Dockerfile.prod, you can connect to database and swagger. In frontend, you arrive on the
LOGIN OR CREATE ACCOUNT
button page. Everything is fine so far. But when you click on the button, you are not redirect to the profile page, and there is this error in the firefox browser console:Chrome browser console seems to provide more hints:
The error maybe comes from the
window.location.href = `${config.backendURL}/auth/callback\;
l.33, in `FortyTwo.vue.I tried to remove
node_modules
's repo, and prune and remove volume from docker.