Travelers Group is a worldwide organization where professionals and non-professionals photographers and artists (all of whom are called publishers) share their work to the internet, to a website. For each photo and album page, there will be ads of Travelers Group partners being displayed. Those ads are monetized based on the number of visualizations, and a percentage of this revenue will be shared with publishers proportional to the visualization of their materials.
- Clone the project
git clone https://github.com/IgorGMoraes/Photo-Gallery.git
- Install Docker
- Pull MySQL image to Docker
docker pull mysql
- Create network for the project
docker network create photogallery
- Inside Photo-Gallery directory create .jar file using maven
mvn package -DskipTests
- Build the docker image for the project
docker image build -t photogallery .
- Run MySQL database as a container
docker container run --network photogallery --name mysqldb -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=photogallery -d mysql:8
- Check if MySQL container is ready
docker container logs -f mysqldb
- Run the application as a container
docker container run --network photogallery --name photogallery-app -p 8080:8080 -d photogallery
- To access the application go to: localhost:8080