JunsuLime / spring-cloud-native-explorer

Spring cloud explorer
1 stars 0 forks source link

빌드팩 (Build pack) #26

Closed JunsuLime closed 2 years ago

JunsuLime commented 2 years ago

클라우드 파운드리는 애플리케이션이 실행되는 환경을 아주 명확하게 가정한다. 이러한 가정은, Heroku 에서 도입한 Buildpack 에 담겨있다.

: 그 위에 실행될 어플리케이션 종류에는 관심이 없다. 대신에 애플리케이션이 담길 리눅스 컨테이너에 신경쓴다. https://buildpacks.io/

JunsuLime commented 2 years ago

The project aims to unify the buildpack ecosystems with a platform-to-buildpack contract

Buildpack 의 specification 에 대하여 (https://github.com/buildpacks/spec/blob/main/buildpack.md) 이를 통해서 source code 를 OCI image 로 묶는다.

The lifecycle program uses buildpacks to build software artifacts from source code and pack the result into an OCI image.

JunsuLime commented 2 years ago

Springboot 2.3 이후부터는 gradle task 의 형태로 OCI image 생성을 지원해준다. https://baeji77.github.io/spring/dev/Spring-boot-gradle-build/

bootBuildImage 라는 명령어를 사용하면 된다.

해당 명령어는 2.3 버전에서 buildpack 을 이용하여 만들어졌다.

https://github.com/opencontainers/image-spec

bootBuildImage 의 결과물 기반으로 로컬환경을 띄워보자