Skip to content

Repository for 'Software Ontwikkel Proces' course at Fontys

Notifications You must be signed in to change notification settings

Martijnvos/SOP6

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SOP6 Docker implementation


📚 Libraries/tools

This project was started the goal of simulating a real software development workflow
with CI (Continuous Integration) and CD (Continuous Deployment).

For this the following libraries/tools are used:

  • Payara as application server (JavaEE)
  • PostgreSQL as database
  • Jenkins as automation server linked with this repo using a Webhook

Some more libraries/tools were necessary to get it all working as we have developed this project with Docker Desktop for
Windows. They will be explained in detail in the next couple of paragraphs.

🌐 Ngrok

Because this project is developed locally there was initially no URL for the Webhook to connect to.
That's where Ngrok comes in. This tool exposes a specified port to the internet using a subdomain.
Downloads for the different operating systems can be found on ngrok.com/download.

After extracting and running the script you can expose Jenkins to the GitHub Webhook like this:

   ngrok http 9090

💾 PostgreSQL shenanigans

Disclaimer: this issue is only present on Windows machines at the time of writing.
When the PostgreSQL container would spin up there would be an error message stating:

FATAL: data directory "/var/lib/postgresql/data" has wrong ownership.  
The server must be started by the user that
owns the data directory.

As this StackOverflow answer shows there's a way around it. While this is not the best solution, we've got no choice judging by the comments (especially this one).

The fix above has been integrated into the docker-compose.yml file.
⚠️ You still need to run docker volume create postgres_database before your first usage though!

Tip: in case you want to know where docker created the volume you can run docker volume inspect postgres_database.

🛠️ Configuration

Configuration steps can be found in jenkins-setup.md , payara-setup.md and sonarqube-setup.md because of the amount of screenshots.
The PostgreSQL database doesn't need further configuration for this project.

About

Repository for 'Software Ontwikkel Proces' course at Fontys

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages