Newer
Older
# Select a base image with Java installed
FROM openjdk:17-slim
# Set the working directory
WORKDIR /app
# Copy the executable jar file of the application to the image
COPY servicespecificationuploader-0.0.1-SNAPSHOT.jar /app/servicespecificationuploader.jar
# Set the command that will run when the container starts
# Note: Pass the data folder path as an environment variable or argument during runtime.
# Example command to pass data folder as a runtime argument:
# docker run -v /local/path/to/config.properties:/app/config.properties -v /local/path/to/your-data-folder:/app/data-folder your-image /app/data-folder
# Updated CMD to accept runtime arguments for data folder
ENTRYPOINT ["sh", "-c", "java -jar /app/servicespecificationuploader.jar --configfile /app/config.properties --servicespecfolderpath $0"]