{"id":21240035,"url":"https://github.com/open-hand/devops-service","last_synced_at":"2025-04-05T00:05:03.347Z","repository":{"id":37631004,"uuid":"134035412","full_name":"open-hand/devops-service","owner":"open-hand","description":"DevOps Service is the core service of Choerodon. It integrated several open source tools to automate the DevOps process of planning, coding, building, testing, and deployment, operation, monitoring.","archived":false,"fork":false,"pushed_at":"2024-11-07T06:44:48.000Z","size":69450,"stargazers_count":62,"open_issues_count":10,"forks_count":77,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-03-28T23:03:16.903Z","etag":null,"topics":["choerodon","devops","gitflow","java","spring","spring-boot","spring-cloud"],"latest_commit_sha":null,"homepage":"http://choerodon.io","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/open-hand.png","metadata":{"files":{"readme":"README.en_US.md","changelog":"CHANGELOG.en-US.md","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":"2018-05-19T06:14:09.000Z","updated_at":"2024-12-17T03:00:02.000Z","dependencies_parsed_at":"2023-02-02T22:15:48.203Z","dependency_job_id":"1ceee1fa-2db8-4e60-be1e-7eb49cc12c71","html_url":"https://github.com/open-hand/devops-service","commit_stats":null,"previous_names":[],"tags_count":246,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-hand%2Fdevops-service","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-hand%2Fdevops-service/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-hand%2Fdevops-service/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/open-hand%2Fdevops-service/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/open-hand","download_url":"https://codeload.github.com/open-hand/devops-service/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247266563,"owners_count":20910836,"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","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":["choerodon","devops","gitflow","java","spring","spring-boot","spring-cloud"],"created_at":"2024-11-21T00:47:32.995Z","updated_at":"2025-04-05T00:05:03.329Z","avatar_url":"https://github.com/open-hand.png","language":"Java","readme":"English | [简体中文](./README.md)\n\n# DevOps Service\n\n`DevOps Service` is the continuous delivery service of Choerodon. Current version: `1.1.0`\n\nDevOps Service integrated several open source tools to automate the process of `planning`, `coding`, `building`, `testing`, `deployment`, `operation` and `monitoring`.\n After a little simple configuration, you'll get the smoothest development experience.\n\n\u003e NOTICE: The previous front code was moved [here](https://github.com/open-hand/choerodon-front-devops)\n\n## Feature\n`DevOps Service` contains features as follows:    \n- `Application Service Management`: Manage the application service\n- `Application service version management`: Manage the versions released during the `Continuous Integration` process of the services, which can be deployed directly in the `Kubernetes` cluster\n- `Code management \u0026 version control`: Manage the code of the application service with version control\n- `Branch management`: Able to operate the git branches of the application service\n- `Code Quality Analysis`：data of code quality are collected during `CI`, `SonarQube` is integrated.\n- `Continuous Integration Overview`: Glance at the `Continuous Integration` process\n- `Deployment Management`: Deploy the versions from `CI` by `GitOps`\n- `Continuous Deployment Pipeline Management`: Achieve the `Continuous Deployment` by workflow\n- `Resource Management`: Manage the resource(e.g., secret)\n- `Cluster Management`: Manage the cluster of `Kubernetes`\n\n## Requirements\n- [JAVA](https://www.java.com/en/): `DevOps Service` is based on java8\n- [GitLab](https://about.gitlab.com/): `GitLab` is used as code repository. At the same time, `Continuous Integration` based on `GitLab Runner` is used to complete code compilation, unit test execution, code quality analysis, docker image generation, helm chart packaging, service version releasing and other automated processes\n- [Harbor](https://vmware.github.io/harbor/cn/): Enterprise Docker registry service for hosting the docker images for the service versions\n- [Kubernetes](https://kubernetes.io/): Container orchestration management tool for deploying the helm chart packages corresponding to the service versions\n- [ChartMuseum](https://chartmuseum.com/): Helm Chart Repository server., which is used to store the helm chart package corresponding to the service versions\n- [Sonarqube](https://www.sonarqube.org/): SonarQube empowers all developers to write cleaner and safer code for application services\n- [MySQL](https://www.mysql.com): one of the most popular relational databases, for data persistence of `DevOps Service`\n- [Redis](https://redis.io/): In-memory database for data caching and partial non-persistent data storage\n\n## Dependencies\n\n* `choerodon-register`: Register server, in place of `eureka-server`\n* `choerodon-iam`：Iam service\n* `choerodon-gateway`: Gateway service\n* `choerodon-oauth`: Oauth service\n* `choerodon-asgard` : Transaction consistency service\n* `choerodon-message` : Notify service\n* `gitlab-service`：Service to communicate with gitlab\n* `workflow-service`：Workflow service\n* `agile-service`：Agile service\n\n## Service Configuration\n\n* `bootstrap.yml`:\n\n  ```yaml\n  server:\n    port: 8060\n  spring:\n    application:\n      name: devops-service\n    cloud:\n      config:\n        failFast: true\n        retry:\n          maxAttempts: 6\n          multiplier: 1.5\n          maxInterval: 2000\n        uri: localhost:8010\n        enabled: false\n    mvc:\n      static-path-pattern: /**\n    resources:\n      static-locations: classpath:/static,classpath:/public,classpath:/resources,classpath:/META-INF/resources,file:/dist\n  management:\n    server:\n      port: 8061\n    endpoints:\n      web:\n        exposure:\n          include: '*'\n  ```\n\n* `application.yml`:\n\n  ```yaml\n  spring:\n    datasource:\n      url: jdbc:mysql://localhost/devops_service?useUnicode=true\u0026characterEncoding=utf-8\u0026useSSL=false\n      username: choerodon\n      password: choerodon\n      hikari:\n        maximum-pool-size: 15\n    redis:\n      host: localhost\n      database: ${SPRING_REDIS_DATABASE:1}\n    http:\n      encoding:\n        charset: UTF-8\n        force: true\n        enabled: true\n  services:\n    harbor:\n      baseUrl: \"harbor.example.com\" # harbor url\n      username: \"123456\" # harbor username\n      password: \"123456\" # password corresponding to harbor user\n      insecureSkipTlsVerify: false\n    gitlab:\n      url: \"gitlab.example.com\" # gitlab url\n      sshUrl: \"gitlab.example.com\" # gitlab url for ssh operations\n      projectLimit: 100 # the limit of the project number that a user can create\n    helm:\n      url: \"helm.example.com\" # the repository url to place helm charts\n    gateway:\n      url: \"http://api.example.com\" # the domain of the hzero gateway\n  hzero:\n    service:\n      platform:\n        name: choerodon-platform\n      oauth:\n        name: choerodon-oauth\n      iam:\n        name: choerodon-iam\n      file:\n        name: choerodon-file\n      message:\n        name: choerodon-message\n      admin:\n        name: choerodon-admin\n      swagger:\n        name: choerodon-swagger\n      gateway:\n        name: choerodon-gateway\n      monitor:\n        name: choerodon-monitor\n    websocket:\n      # the path for websocket connection\n      websocket: /websocket\n      # consistent with the redis db above\n      redisDb: ${SPRING_REDIS_DATABASE:1}\n      # the secret for websocket\n      secretKey: devops_ws\n  choerodon:\n    saga:\n      consumer:\n        core-thread-num: 20\n        max-thread-num:  20 # consumer thread number\n        poll-interval: 3 # the interval for polling messages, default 1s\n        enabled: true # whether to enable consumer client\n    schedule:\n      consumer:\n        enabled: true # enable schedule consume\n        thread-num: 1 # thread number for consuming\n        poll-interval-ms: 1000 # the interval for polling messages, default 1000ms\n    resource:\n      jwt:\n        ignore: /workflow/**, /sonar/**, /ci, /sonar/info, /v2/api-docs, /agent/**, /ws/**, /gitlab/email, /webhook/**, /v2/choerodon/**, /choerodon/**, /actuator/**, /prometheus, /devops/**, /pre_stop, /websocket\n  agent:\n    version: \"0.5.0\" # expect choerodon-agent version for this devops-service version\n    serviceUrl: \"agent.example.com\" # url for choerodon-agent to connect devops-service\n    certManagerUrl: \"agent.example.com\" # the location to store the CertManager for installation\n    repoUrl: \"helm.example.com\" # the location to store the agent package itself for installation\n  mybatis:\n    mapperLocations: classpath*:/mapper/*.xml\n    configuration:\n      mapUnderscoreToCamelCase: true\n  feign:\n    hystrix:\n      shareSecurityContext: true\n      command:\n        default:\n          execution:\n            isolation:\n              thread:\n                timeoutInMilliseconds: 30000\n  ribbon:\n    ConnectTimeout: 50000\n    ReadTimeout: 50000\n\n  asgard-servie:\n    ribbon:\n      ConnectTimeout: 50000\n      ReadTimeout: 50000\n\n  # websocket max buffer size (byte)\n  websocket:\n    buffer:\n      maxTextMessageSize: 4194304\n      maxBinaryMessageSize: 4194304\n  devops:\n    ansible:\n      image: registry.cn-shanghai.aliyuncs.com/c7n/kubeadm-ha:0.1.0\n    # helm download url\n    helm:\n      download-url: https://file.choerodon.com.cn/kubernetes-helm/v3.2.4/helm-v3.2.4-linux-amd64.tar.gz\n    # The default runner mirror address in the Gitlab Ci file generated by ci pipeline\n    ci:\n      default:\n        image: registry.cn-shanghai.aliyuncs.com/c7n/cibase:0.9.1\n      pipeline:\n        sync:\n          executor:\n            corePoolSize: 5\n            maxPoolSize: 8\n          unterminated:\n            # The time threshold for data compensation of the ci pipeline to the unterminated pipeline, unit: milliseconds (default 600 seconds)\n            thresholdMilliSeconds: 600000\n          pending:\n            # The time threshold for the ci pipeline to compensate the pending pipeline, unit: milliseconds (default 600 seconds)\n            thresholdMilliSeconds: 600000\n          jobEmpty:\n            # threshold to complete data if non data for job, ms: (default 600seconds)\n            thresholdMilliSeconds: 600000\n          refresh:\n            # redisKey expiration, control the refresh period\n            periodSeconds: 60\n    # the size for max batch deployment\n    batch:\n      deployment:\n        maxSize: 20\n  ```\n\n## Installation and Getting Started\n1. create database `devops_service`, create user `choerodon` and grant permission:\n\n   ```sql\n   CREATE USER 'choerodon'@'%' IDENTIFIED BY \"choerodon\";\n   CREATE DATABASE devops_service DEFAULT CHARACTER SET utf8;\n   GRANT ALL PRIVILEGES ON devops_service.* TO choerodon@'%';\n   FLUSH PRIVILEGES;\n   ```\n\n2. pull source code of `DevOps Service`:\n\n   ```sh\n   git clone https://github.com/choerodon/devops-service.git\n   ```\n\n3. Execute command in the project root directory: `mvn clean package spring-boot:repackage -Dmaven.test.skip=true \u0026\u0026 bash init-database.sh`\n\n4. Run with the following commands or run `DevopsServiceApplication` directly in the integrated environment:\n\n   ```sh\n   mvn clean spring-boot:run\n   ```\n\n## Links\n\n[ChangeLog](./CHANGELOG.en-US.md)\n\n## Reporting Issues\nIf you find any shortcomings or bugs, please describe them in the  [issue](https://github.com/choerodon/devops-service/issues/new).\n\n## How to Contribute\nPull requests are welcomed! [Follow](https://github.com/choerodon/choerodon/blob/master/CONTRIBUTING.md) to know for more information on how to contribute.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopen-hand%2Fdevops-service","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopen-hand%2Fdevops-service","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopen-hand%2Fdevops-service/lists"}