Add Java CI/CD pipeline workflow #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Java CICD Pipeline | |
| on: | |
| push: | |
| branches: [ main ] | |
| workflow_dispatch: | |
| jobs: | |
| java: | |
| runs-on: self-hosted | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: build the project | |
| run: mvn clean package | |
| - name: Changing the directory | |
| run: cd target | |
| - name: Run ColorFul App | |
| run: | | |
| java -jar colorful-app-1.0.0.jar | |
| curl http://localhost:8080 | |