Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Code Scan Action #2366

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Add Code Scan Action #2366

wants to merge 2 commits into from

Conversation

Duan-0916
Copy link

Motivation:
为了增强代码审查流程并确保代码的安全性和合规性,我新增了代码安全扫描和开源组件扫描。通过加入这些扫描,我们可以识别潜在的漏洞,并确保代码库符合开源项目治理标准化的要求。

Modification:
新增了cloud_code_scan.yml模板,添加了代码安全扫描和开源组件扫描步骤。这些步骤将作为工作流的一部分进行执行,以执行必要的安全检查和合规性验证。通过添加这些扫描,我们可以积极解决安全问题,并确保遵守开源许可协议。

Result:
通过引入代码安全扫描和开源组件扫描,增强了代码审查流程。它有助于识别安全漏洞,并确保符合开源许可要求。这一改进有助于提高代码库的整体质量和安全性。

Copy link

codecov bot commented Dec 20, 2023

Codecov Report

Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (1a41fed) 60.71% compared to head (97a5ffa) 60.72%.
Report is 2 commits behind head on master.

❗ Current head 97a5ffa differs from pull request most recent head 6d48b46. Consider uploading reports for the commit 6d48b46 to get more accurate results

Files Patch % Lines
pkg/filter/network/grpc/factory.go 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##           master    #2366   +/-   ##
=======================================
  Coverage   60.71%   60.72%           
=======================================
  Files         426      426           
  Lines       37718    37719    +1     
=======================================
+ Hits        22902    22906    +4     
+ Misses      12565    12564    -1     
+ Partials     2251     2249    -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -0,0 +1,22 @@
name: Alipay Cloud Devops Codescan
on:
pull_request_target:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need more action to triger Github Action:

on:
  push:
    branches:
      - master
  pull_request:
    types:
      - opened
      - reopened
      - synchronize
      - ready_for_review

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull_ Request_ The target basically includes these actions, and currently uses pull_ There may be some errors in the request

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

我认为显式指定 types 更加优雅,更加直观,可读性更高,

默认情况下,工作流仅在 pull_request_target 事件的活动类型为 opened、synchronize 或 reopened 时运行。
https://docs.github.com/zh/actions/using-workflows/events-that-trigger-workflows#pull_request_target

on:
  push:
    branches:
      - master

这个配置也是有必要的,你没发现,你添加这个 workflow 后,你自己没触发过吗?如果不配置这个,像你这种贡献 workflow action 的人就没办法去触发验证该 workflow

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

可以的,我这边加一下

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

现在我们这边只支持pr触发,push这块暂时还没有

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants