The application layer of the containerized Web App project.
190
This Docker image is designed to run the VProfile project, a sample Three-tiered Java web application. The image leverages Maven and Tomcat to build and serve the application. The detailed description, usage instructions, and other relevant information below.
openjdk:11 for the build stage and tomcat:9-jre11 for the runtime stage.Stage 1: Build Image
openjdk:11 is used.docker branch and built using Maven.Stage 2: Runtime Image
tomcat:9-jre11 is used.vprofile-v2.war) is copied from the build stage and deployed to Tomcat.To pull the Docker image from DockerHub:
docker pull ardhendushekhar/vprofileapp:latest
To run the Docker container:
docker run -d -p 8080:8080 ardhendushekhar/vprofileapp:latest
This command will start a container with the VProfile application accessible at http://localhost:8080.
For a more complex setup or multi-container environments, you can use Docker Compose. Below is an example docker-compose.yml:
version: '3'
services:
vprofile:
image: ardhendushekhar/vprofileapp:latest
ports:
- "8080:8080"
Run this with after making appropriate changes:
docker-compose up -d
If you want to build the Docker image locally:
Clone the repository:
git clone https://github.com/devopshydclub/vprofile-project.git
cd vprofile-project
Build the Docker image:
docker build -t ardhendushekhar/vprofileapp:latest .
Run the Docker container:
docker run -d -p 8080:8080 ardhendushekhar/vprofileapp:latest
The container can be customized with the following environment variables:
JAVA_OPTS: Custom Java options to run the Tomcat server.CATALINA_OPTS: Custom options for Tomcat.If you wish to contribute to this project, please follow these steps:
git checkout -b feature/YourFeature).git commit -am 'Add some feature').git push origin feature/YourFeature).This Docker image simplifies the deployment process of the VProfile project, ensuring a consistent environment and reducing setup time. Enjoy developing and deploying your Java web applications with ease!
Content type
Image
Digest
sha256:4ddd000fd…
Size
146.6 MB
Last updated
almost 3 years ago
docker pull ardhendushekhar/vprofileapp