{"id":17810777,"url":"https://github.com/favourdaniel/github-actions-with-springboot-and-ec2","last_synced_at":"2026-05-03T16:31:34.408Z","repository":{"id":48791824,"uuid":"517019512","full_name":"FavourDaniel/github-actions-with-springboot-and-ec2","owner":"FavourDaniel","description":"This project shows how Github Actions work","archived":false,"fork":false,"pushed_at":"2022-08-11T16:57:30.000Z","size":87,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-02T07:13:14.633Z","etag":null,"topics":["aws","cicd","java","springboot"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FavourDaniel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-07-23T09:54:57.000Z","updated_at":"2024-04-14T18:40:00.000Z","dependencies_parsed_at":"2022-08-12T19:51:07.734Z","dependency_job_id":null,"html_url":"https://github.com/FavourDaniel/github-actions-with-springboot-and-ec2","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/FavourDaniel/github-actions-with-springboot-and-ec2","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FavourDaniel%2Fgithub-actions-with-springboot-and-ec2","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FavourDaniel%2Fgithub-actions-with-springboot-and-ec2/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FavourDaniel%2Fgithub-actions-with-springboot-and-ec2/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FavourDaniel%2Fgithub-actions-with-springboot-and-ec2/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FavourDaniel","download_url":"https://codeload.github.com/FavourDaniel/github-actions-with-springboot-and-ec2/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FavourDaniel%2Fgithub-actions-with-springboot-and-ec2/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32577119,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-03T06:36:36.687Z","status":"ssl_error","status_checked_at":"2026-05-03T06:36:09.306Z","response_time":103,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aws","cicd","java","springboot"],"created_at":"2024-10-27T15:40:21.434Z","updated_at":"2026-05-03T16:31:34.384Z","avatar_url":"https://github.com/FavourDaniel.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Github-Actions-with-Springboot-and-EC2\n![Frame 1 (5)](https://user-images.githubusercontent.com/89241109/180608741-a66186cc-a5ee-479a-987f-6bede1720e45.png)\n\nThis project demonstrates how to create a continuous integration pipeline such that if a change is made to the repository, updates are automatically built and pushed to the ec2 instance.\n\n---\n## Pre-requisites \u0026 Installation guide\nWorking knowledge of CICD, aws, a code editor.\n\n### Create an EC2 instance\n- In your security group inboud rules setting, open ssh for port 22 - custom and open tcp for port 80 - anywhere\n- Allocate an elastic IP address to your instance to provide you with a static ip (optional)\n### \n\n---\n# Project Setup\n### Step 1: Clone this repository\n```\ngit clone \u003cREPO_URL\u003e\n```\n### Step 2: Edit the repo by adding your instance details where expected.\n\n### Step 3: ssh into your ec2 instance\n```\nsudo ssh -i \"yourkeypairname.pem\" instancetype@instancepubliciddress.region.compute.amazonaws.com\n```\nIf you do not understand the above, the below is an example\n```\nsudo ssh -i \"cicdkey.pem\" ubuntu@ec3-4-5-22-13.us-east-1.compute.amazonaws.com\n```\nNB: ensure you are in the directory where your key pair is present.\n\n### Step 4: Setup Github Actions\nPush the project to github and in the settings tab, select Actions \u003e\u003e Runners \u003e\u003e Then create a new self-hosted runner\n\n![cicd 1](https://user-images.githubusercontent.com/89241109/181905295-dba86632-5248-4653-8acb-84575e4e90a4.png)\n\nAfter creating the self-hosted runner, select the runner image depending on what kind of instance you created, the copy and paste all the commands under ```Download``` to your ec2 instance which you have sshed into\n![cicd2 1](https://user-images.githubusercontent.com/89241109/181905305-29f3417f-dbf3-4234-bcb4-0c8bc09a6a59.png)\n\nOnce you have copied and pasted the ```Download``` commands, copy and past the ```Configure``` commands as well\n![cicd3 1](https://user-images.githubusercontent.com/89241109/181905312-79268e5f-5e41-4cce-853a-834eeae79e0f.png)\n\n### Step 5: Further Installations\nAfter setup, some specifics in the project need to be installed for the runner to do its work. If you ```ls``` you would see the files that the runner presently contains.\n```\nsudo ./svc.sh install\n```\nAfter installing in, start it\n```\nsudo ./svc.sh start\n```\nThis command automatically connects your project with Github/the repo.\n\n### Step 5: Setup Workflow\nThe workflow for this project has already been setup but if you would like to set it up your own, delete the ```maven.yml``` file.\nNavigate to actions tab on the in the repository and select ```Java with Maven```. \n![cicd4 1](https://user-images.githubusercontent.com/89241109/181905910-80c574ac-8b83-4eaa-979e-ee3448403cc3.png)\n\nInside the workflow, in jobs \u003e\u003e builds \u003e\u003e runs-on, change ```ubuntu-latest``` to ```self-hosted``` because we are using a self-hosted runner. You can take out the ```pull_request: branches``` since it is not necessary, then commit.\n![cicd5 1](https://user-images.githubusercontent.com/89241109/181905914-52a72a71-599d-422f-aa57-f6094d457831.png)\n\n### Step 6: Installing dependencies\nJdk needs to be installed in the instance. In the actions-runner directory, ```cd`` and update pacakages first\n```\nsudo apt update\n```\nThen\n```\nsudo apt install maven openjdk-11-jre openjdk-11-jdk\n```\nWith dependencies in place, builds made will run and be visble on github\n\nYou can check your instance ip address to view the site.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffavourdaniel%2Fgithub-actions-with-springboot-and-ec2","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffavourdaniel%2Fgithub-actions-with-springboot-and-ec2","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffavourdaniel%2Fgithub-actions-with-springboot-and-ec2/lists"}