{"id":31646071,"url":"https://github.com/codefresh-io/cf-deploy-kubernetes","last_synced_at":"2025-10-07T05:19:46.209Z","repository":{"id":21317118,"uuid":"72735492","full_name":"codefresh-io/cf-deploy-kubernetes","owner":"codefresh-io","description":"A Codefresh step to deploy to Kubernetes","archived":false,"fork":false,"pushed_at":"2025-09-14T18:40:27.000Z","size":100,"stargazers_count":12,"open_issues_count":17,"forks_count":18,"subscribers_count":16,"default_branch":"master","last_synced_at":"2025-09-14T20:37:04.978Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Shell","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/codefresh-io.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2016-11-03T10:44:29.000Z","updated_at":"2025-06-10T07:53:33.000Z","dependencies_parsed_at":"2023-01-12T03:45:26.975Z","dependency_job_id":"2eea6bdf-66e5-44b4-b1e9-fdc1e459902d","html_url":"https://github.com/codefresh-io/cf-deploy-kubernetes","commit_stats":null,"previous_names":[],"tags_count":21,"template":false,"template_full_name":null,"purl":"pkg:github/codefresh-io/cf-deploy-kubernetes","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codefresh-io%2Fcf-deploy-kubernetes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codefresh-io%2Fcf-deploy-kubernetes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codefresh-io%2Fcf-deploy-kubernetes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codefresh-io%2Fcf-deploy-kubernetes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codefresh-io","download_url":"https://codeload.github.com/codefresh-io/cf-deploy-kubernetes/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codefresh-io%2Fcf-deploy-kubernetes/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278722757,"owners_count":26034463,"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":[],"created_at":"2025-10-07T05:19:44.593Z","updated_at":"2025-10-07T05:19:46.204Z","avatar_url":"https://github.com/codefresh-io.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Abstract\n\nThis is the source code for the `codefresh/cf-deploy-kubernetes` container.\nThis container is used to demonstrate a Kubernetes deployment using Codefresh.io\n\n# Assumptions\n\nThe deployment script makes the following assumptions about your application and\nKubernetes configuration:\n\n1. The application is deployed using the Kubernetes deployment API (versus the\nthe replication controller directly). For more information read\nhttp://kubernetes.io/docs/user-guide/deployments/\n2. The tested codebase has a yaml file (i.e. deployment.yml) that describes the Kubernetes deployment\nparameters and configuration of your application.\n3. The script processes deployment.yml as a simple template where all `{{ ENV_VARIABLE }}` are replaced with a value of $ENV_VARIABLE deployment.yml\n\n# Configuration\n\nThe following env variables control the deployment configuration:\n\n1. KUBERNETES_DEPLOYMENT_TIMEOUT - How much to wait for a successful deployment before failing the build. Defaults to 120 (secs).\n2. KUBECONTEXT - corresponds to the name of a cluster added to codefresh\n3. KUBERNETES_NAMESPACE - The namespace to deploy\n4. KUBECTL_ACTION - means an action for `kubectl \u003caction\u003e`. Valid values are apply|create|replace. Default is \"apply\"\n\nOptional:\n\n`SERVER_VERSION` - Manually set the Minor kubectl version.  Supports 10-22.\n\n# Usage in codefresh.io\n\n### deployment.yml\n\n```yaml\n---\napiVersion: extensions/v1beta1\nkind: Deployment\nmetadata:\n  name: api-svc\nspec:\n  replicas: 1\n  template:\n    metadata:\n      annotations:\n        revision: \"{{CF_REVISION}}\"\n      labels:\n        app: api-svc\n    spec:\n      containers:\n        - name: apisvc\n          image: myrepo/apisvc:{{CF_BRANCH}}-{{CF_REVISION}}\n          ports:\n            - containerPort: 80\n              name: http\n\n```\n\n### codefresh.yml\n```yaml\n---\nversion: '1.0'\n\nsteps:\n  build:\n    type: build\n    dockerfile: Dockerfile\n    image_name: myrepo/apisvc\n    tag: '${{CF_BRANCH}}-{{CF_REVISION}}'\n    \n  push:\n    type: push\n    candidate: ${{build}}\n    tag: '${{CF_BRANCH}}-{{CF_REVISION}}'\n\n  deploy-to-kubernetes:\n    image: codefresh/cf-deploy-kubernetes\n    tag: latest\n    working_directory: ${{clone}}\n    commands:\n      - /cf-deploy-kubernetes deployment.yml\n    environment:\n      - KUBECONTEXT=my-clusterg@my-staging\n      - KUBERNETES_NAMESPACE=mynamespace\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodefresh-io%2Fcf-deploy-kubernetes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodefresh-io%2Fcf-deploy-kubernetes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodefresh-io%2Fcf-deploy-kubernetes/lists"}