若依图片上传成功不能显示的解决办法

2237人浏览 / 0人评论 / 添加收藏

文件上传成功后,请求访问后台地址会根据​​profile​​​进行匹配,需要自己配置​​nginx​​代理。

方式一:指向地址
location /profile/ {
   proxy_pass http://127.0.0.1:8080/profile/; 
}

方法二:指向目录,对应后台`application.yml`中的`profile`配置

location /profile/
{
   alias /home/ruoyi/uploadPath/;
}
 

全部评论