๊ด€๋ฆฌ ๋ฉ”๋‰ด

ruriruriya

[Spring Boot] ์Šคํ”„๋ง ๋ถ€ํŠธ์˜ ์ •์  ์ปจํ…์ธ  ๊ธฐ๋Šฅ ๋ณธ๋ฌธ

๐Ÿ–Œ๏ธWeb/Spring Boot

[Spring Boot] ์Šคํ”„๋ง ๋ถ€ํŠธ์˜ ์ •์  ์ปจํ…์ธ  ๊ธฐ๋Šฅ

๋ฃจ๋ฆฌ์•ผใ…‘ 2024. 3. 11. 21:04
๋ฐ˜์‘ํ˜•

์Šคํ”„๋ง๋ถ€ํŠธ์—๋Š” ์ •์  ์ปจํ…์ธ ๋ฅผ ์˜ฌ๋ฆด ์ˆ˜ ์žˆ๋Š” ๊ธฐ๋Šฅ์ด ์žˆ๋‹ค.
์•„๋ž˜๋Š” ์ •์ ์ปจํ…์ธ ๋ฅผ ์Šคํ”„๋ง์ด ์‹คํ–‰ํ•˜๋Š” ์ˆœ์„œ์ด๋‹ค.

์Šคํ”„๋ง๋ถ€ํŠธ ๊ณต์‹ ์‚ฌ์ดํŠธ ๋ฉ”๋‰ด์–ผ์„ ๋จผ์ € ์‚ดํŽด๋ณด๋ฉด
/static ํด๋”์— ํŒŒ์ผ์„ ์ƒ์„ฑํ•ด์„œ ๋ถˆ๋Ÿฌ์˜ฌ ์ˆ˜ ์žˆ๋‹ค.

https://docs.spring.io/spring-boot/docs/2.3.1.RELEASE/reference/html/spring-boot-features.html#boot-features-spring-mvc-static-content

 

Spring Boot Features

Graceful shutdown is supported with all four embedded web servers (Jetty, Reactor Netty, Tomcat, and Undertow) and with both reactive and Servlet-based web applications. It occurs as part of closing the application context and is performed in the earliest

docs.spring.io

 

src/main/resources/static์— html์„ ์ƒ์„ฑํ•œ ๋’ค

์‹คํ–‰ํ•˜์—ฌ ๋กœ์ปฌ์—์„œ ํ…Œ์ŠคํŠธํ•˜๋ฉด ์ •์ƒ ์ž‘๋™ํ•˜๋Š” ๊ฒƒ์„ ๋ณผ ์ˆ˜ ์žˆ๋‹ค.

 

์ด ์ฒ˜๋Ÿผ ๋‹จ์ˆœํ•˜๊ฒŒ ํ™”๋ฉด์— ์ •์ ์ฝ˜ํ…์ธ ๋ฅผ ๋ณด์—ฌ์ฃผ๋Š” ๊ธฐ๋Šฅ์ด๋‹ค.

๋ฐ˜์‘ํ˜•