Skip to content

Latest commit

 

History

History
41 lines (33 loc) · 1.11 KB

File metadata and controls

41 lines (33 loc) · 1.11 KB

Config Server

Gradle

Build application using below command

gradle clean build

or

./gradlew clean build
Docker image
export CONFIG_SERVER_VERSION=<version>
docker pull ghcr.io/raghav2211/spring-web-flux-todo-app/config-server:${CONFIG_SERVER_VERSION}

or

docker build --build-arg JAR_FILE=build/libs/config-server-${CONFIG_SERVER_VERSION}.jar --tag config-server:${CONFIG_SERVER_VERSION} .

Access

http://localhost:8888/todo/local

Pushing Image to ECR

$ export AWS_REGION=<aws.region>
$ export AWS_ACCOUNT_ID=<aws.account.id>
# create if not exists
$ aws ecr create-repository --repository-name config-server 
$ aws ecr get-login-password --region ${AWS_REGION} | docker login --username AWS --password-stdin ${AWS_ACCOUNT_ID}.dkr.ecr.${AWS_REGION}.amazonaws.com
$ docker tag config-server:${CONFIG_SERVER_VERSION} ${AWS_ACCOUNT_ID}.dkr.ecr.${AWS_REGION}.amazonaws.com/config-server:${CONFIG_SERVER_VERSION}
$ docker push ${AWS_ACCOUNT_ID}.dkr.ecr.${AWS_REGION}.amazonaws.com/config-server:${CONFIG_SERVER_VERSION}