前提・実現したいこと
SprinbBootでWebアプリケーションを作成しました。
これをさくらVPS上に配置して利用できるようにしたいと考えています。
発生している問題・エラーメッセージ
サーバルートのURLにアクセスると、以下のExceptionが発生します。
Error resolving template [index], template might not exist or might not be accessible by any of the configured Template Resolvers
該当のソースコード
Java
1 @GetMapping("/") 2 public String getIndex() { 3 return "index"; 4 }
試したこと
return の先頭のスラッシュを入れない。
https://www.lifestyle12345.com/2019/05/error-spring-boot-jar.html
補足情報(FW/ツールのバージョンなど)
FW:SprinbBoot 2.6.1
テンプレートエンジン:Thymeleaf
SprinbBoot Securityは不使用
サーバ:さくらVPS
OS:CentOS7 x86_64
不足情報がありましたらご指摘頂ければと思います。
よろしくお願いします。
あなたの回答
tips
プレビュー