{"id":31358304,"url":"https://github.com/leonsteinhaeuser/rh-ocp-examples","last_synced_at":"2025-10-07T07:47:36.938Z","repository":{"id":263855975,"uuid":"888389620","full_name":"leonsteinhaeuser/rh-ocp-examples","owner":"leonsteinhaeuser","description":"Red Hat OpenShift application deployment examples.","archived":false,"fork":false,"pushed_at":"2024-12-05T10:29:10.000Z","size":124,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-09-26T21:58:32.622Z","etag":null,"topics":["argocd","gitops","ocp","openshift","redhat","redhat-ocp","redhat-openshift"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leonsteinhaeuser.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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-11-14T10:11:27.000Z","updated_at":"2024-12-05T10:29:14.000Z","dependencies_parsed_at":"2024-11-20T17:25:24.818Z","dependency_job_id":"673ac420-fad0-4ce5-8547-9a0dc9db2030","html_url":"https://github.com/leonsteinhaeuser/rh-ocp-examples","commit_stats":null,"previous_names":["leonsteinhaeuser/rh-ocp-examples"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/leonsteinhaeuser/rh-ocp-examples","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leonsteinhaeuser%2Frh-ocp-examples","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leonsteinhaeuser%2Frh-ocp-examples/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leonsteinhaeuser%2Frh-ocp-examples/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leonsteinhaeuser%2Frh-ocp-examples/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leonsteinhaeuser","download_url":"https://codeload.github.com/leonsteinhaeuser/rh-ocp-examples/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leonsteinhaeuser%2Frh-ocp-examples/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278740817,"owners_count":26037480,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["argocd","gitops","ocp","openshift","redhat","redhat-ocp","redhat-openshift"],"created_at":"2025-09-26T21:58:17.627Z","updated_at":"2025-10-07T07:47:36.931Z","avatar_url":"https://github.com/leonsteinhaeuser.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rh-ocp-examples\n\nRed Hat OpenShift application deployment examples.\n\n## Repository structure\n\n```txt\n- services                # Services\n  - number                # A demo service that generates a random number (Go code)\n  - status                # A demo service that returns the status of the upstream service (Go code)\n  - view                  # A demo service that displays the random number (Go code)\n- ocp                     # OpenShift deployment and management resources\n  - deployments           # ArgoCD Application resources for the services\n    - helm                ä Helm value files\n      - basic             # Helm value files for the basic deployment via Helm chart\n    - manifests           # Kubernetes manifests for the services (different deployment strategies)\n      - basic             # Kubernetes manifests for the basic deployment\n      - progressive       # Kubernetes manifests for the progressive deployment\n      - servicemesh       # Kubernetes manifests for the application deployment based on the istio service mesh\n  - helm-charts           # Helm charts for the services\n    - number-service      # Helm chart for the number service\n    - status-service      # Helm chart for the status service\n    - view-service        # Helm chart for the view service\n```\n\n## Prerequisites\n\n- OpenShift \u003e= 4.17 cluster\n- Enabled GitOps subscription in the OpenShift cluster (ArgoCD)\n- `oc` CLI installed and configured to access the OpenShift cluster\n\n## How to deploy\n\nBefore we can deploy any of the services, we need to modify our central ArgoCD management application to allow sourcing `Application` resources from other than the `openshift-gitops` namespace. This is necessary because the services are deployed in a separate project, namespace and ArgoCD application and by default, ArgoCD only watches the `openshift-gitops` namespace for `Application` resources.\n\nTo do this, execute the following patch command:\n\n```bash\noc -n openshift-gitops patch argocds.argoproj.io openshift-gitops \\\n  --type merge \\\n  --patch '{\"spec\":{\"sourceNamespaces\":[\"openshift-gitops\",\"example-application-basic\",\"example-application-basic-servicemesh\",\"example-application-progressive\",\"example-application-helm-basic\",\"example-application-helm-progressive\",\"hcp-operators\"]}}'\n```\n\nThe `openshift-gitops` namespace is the `default` namespace and might not be necessary to add to the `sourceNamespaces` list. However, it is added here for completeness.\n\n### Deploy the services\n\n1. Clone the repository\n\n```bash\ngit clone git@github.com:leonsteinhaeuser/rh-ocp-examples.git\ncd rh-ocp-examples\n```\n\n2. Deploy the management app and project\n\n```bash\noc apply --server-side -f ./\n```\n\n3. Wait for ArgoCD to sync the other project setup manifests stored in the `ocp/deployments` directory\n\n4. Wait for the ArgoCD services and applications to be created\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleonsteinhaeuser%2Frh-ocp-examples","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleonsteinhaeuser%2Frh-ocp-examples","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleonsteinhaeuser%2Frh-ocp-examples/lists"}