{"id":18823519,"url":"https://github.com/ocp-devspaces-gamification/ds-challenge-04","last_synced_at":"2026-01-26T01:33:07.305Z","repository":{"id":270291333,"uuid":"869882219","full_name":"ocp-devspaces-gamification/ds-challenge-04","owner":"ocp-devspaces-gamification","description":null,"archived":false,"fork":false,"pushed_at":"2024-10-19T06:49:09.000Z","size":779,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-05-22T11:17:08.375Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HTML","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/ocp-devspaces-gamification.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-09T04:05:24.000Z","updated_at":"2024-12-22T23:46:21.000Z","dependencies_parsed_at":"2024-12-30T04:32:53.599Z","dependency_job_id":null,"html_url":"https://github.com/ocp-devspaces-gamification/ds-challenge-04","commit_stats":null,"previous_names":["ocp-devspaces-gamification/ds-challenge-04"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ocp-devspaces-gamification/ds-challenge-04","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ocp-devspaces-gamification%2Fds-challenge-04","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ocp-devspaces-gamification%2Fds-challenge-04/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ocp-devspaces-gamification%2Fds-challenge-04/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ocp-devspaces-gamification%2Fds-challenge-04/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ocp-devspaces-gamification","download_url":"https://codeload.github.com/ocp-devspaces-gamification/ds-challenge-04/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ocp-devspaces-gamification%2Fds-challenge-04/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28763948,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-26T00:37:26.264Z","status":"ssl_error","status_checked_at":"2026-01-26T00:37:25.959Z","response_time":113,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: 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":[],"created_at":"2024-11-08T00:53:56.029Z","updated_at":"2026-01-26T01:33:07.283Z","avatar_url":"https://github.com/ocp-devspaces-gamification.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Challenge-04\n\n### Scenario\n* Lets continue to built on top of ds-challenge-03\n* This section will explore on adding additional resources to the environment. There will be situations where a certain service testing needs more resources. In a traditional laptop, these type of resources may not be available either due to resource constraints or because the workload under test needs specific types of resources (example: GPUs). That forces the developers to either upgrade their laptops/desktops (which takes time) and or create a whole new setup on another machines. Let's see how we can avoid this pain point using DevSpaces\n\n### Set Up + verification\n* In devspaces, Open a terminal. Run the below command to change the mvnw file to be executable\n  ```bash\n  chmod 755 mvnw\n  ```\n* Refer to the Resources section and find out how to add memory and cpu requirements in devfile containers\n* Add constructs for Resources to the \"tools\" container\n    * Memory    : [Request : 512MB          and Limit : 2Giga Bytes]\n    * CPU       : [Request : 500millicore   and Limit : 2000 millicore] \n* Add a \"Post Start\" event in the devfile to leverage the package command. \n\n\n### Success Criteria\n* The devfile is updated with the memory and cpu requests and limits\n* Reload the devspaces [Click the Arrows symbol(\u003e\u003c) in the Bottom Left corner to open a new menu] with option \"Restart Workspace from Local Devfile\".\n  \u003e Due to the post start task, this process will take a while because the DevSpaces is downloading all the libraries. The UI is shown after the downloads are complete \n \n  ![ ](docs/images/challenge04.reload.jpg)\n\n* After reloading when you run the task \"2. Start Development mode\", you will notice it is quicker\n\n### Resources \n* https://devfile.io/docs/2.2.2\n* https://devfile.io/docs/2.2.2/adding-event-bindings\n\n### What did we learn?\n* OpenShift DevSpaces reduces the Developers pain points. As a Developer, your life is getting simpler with the below\n    * Automatic Extensions (Language Support for Java(TM) by Red Hat) inclusion\n    * Automatic provisioning of required command line tools\n    * Consistent way of building, packaging and running the programs making faster iterative development\n    * Consistent way of creating standardized end points for current and future testing\n* Now you can \n    * Request additional resources easily similar to any workload in the kubernetes\n    * Add events to your IDE which can allow to do tasks : before start, after start or after stop of the workspace\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Focp-devspaces-gamification%2Fds-challenge-04","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Focp-devspaces-gamification%2Fds-challenge-04","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Focp-devspaces-gamification%2Fds-challenge-04/lists"}