Skip to content

Commit

Permalink
Update build version
Browse files Browse the repository at this point in the history
  • Loading branch information
nqhoan-axonivy committed Aug 6, 2024
1 parent 53b5546 commit f32b1b1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,5 @@ jobs:
- name: Build and bring up containers without cache
working-directory: ./marketplace-build
run: |
docker compose build --no-cache --build-arg BUILD_ENV=${{ inputs.build_env }}
docker compose build --no-cache --build-arg BUILD_ENV=${{ inputs.build_env }} --build-arg BUILD_VERSION=${{ inputs.release_version }}
docker compose up --force-recreate -d
2 changes: 2 additions & 0 deletions marketplace-build/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ services:
build:
context: ../marketplace-service
dockerfile: Dockerfile
args:
- BUILD_VERSION=${BUILD_VERSION}
ports:
- "8080:8080"
depends_on:
Expand Down
3 changes: 2 additions & 1 deletion marketplace-service/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ WORKDIR /app
RUN rm -rf /usr/local/tomcat/webapps/ROOT

# Copy the WAR file to the webapps directory in Tomcat
COPY --from=build-api /app/target/marketplace-service-0.0.1-SNAPSHOT.war /usr/local/tomcat/webapps/marketplace-service.war
ARG BUILD_VERSION
COPY --from=build-api /app/target/marketplace-service-${BUILD_VERSION}.war /usr/local/tomcat/webapps/marketplace-service.war

# Expose port 8080
EXPOSE 8080
Expand Down

0 comments on commit f32b1b1

Please sign in to comment.