I am trying to build a Rocket.rs chat app but when I compile the final release version and move it to a different directory, it gives the following error:
Error: FileServer path '/workspaces/Chat/static' is not a directory.
>> Aborting early to prevent inevitable handler error.
thread 'main' panicked at src/main.rs:169:21:
invalid directory: refusing to continue
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
Aborted (core dumped)
How would I run it on this new system without moving it to the directory that it was compiled in? All of the static files were moved as well. I cannot recompile the program on the new system since it does not work (locks up most of the time, likely due to a lack of resources). The line in question is the following:
.mount("/", FileServer::from(relative!("static")))
^