File tree Expand file tree Collapse file tree 2 files changed +66
-0
lines changed Expand file tree Collapse file tree 2 files changed +66
-0
lines changed Original file line number Diff line number Diff line change
1
+ # GitHub Actions Bandit Workflow
2
+
3
+ name : Bandit
4
+
5
+ on :
6
+ pull_request :
7
+ branches : [ master ]
8
+
9
+ workflow_dispatch :
10
+
11
+ jobs :
12
+ build :
13
+ runs-on : ubuntu-latest
14
+
15
+ steps :
16
+ - uses : actions/checkout@v2
17
+
18
+ # Task will fail if any high-severity issues are found
19
+ # Ignoring submodules
20
+ - name : Run Bandit Security Analysis
21
+ run : |
22
+ python -m pip install bandit
23
+ python -m bandit -r . -x ./third_party -lll
Original file line number Diff line number Diff line change
1
+ # GitHub Actions CodeQL Workflow
2
+
3
+ name : CodeQL
4
+
5
+ on :
6
+ pull_request :
7
+ branches : [ master ]
8
+
9
+ workflow_dispatch :
10
+
11
+ jobs :
12
+ build :
13
+ runs-on : ubuntu-latest
14
+
15
+ steps :
16
+ - uses : actions/checkout@v2
17
+
18
+ - name : Initialize CodeQL
19
+ uses : github/codeql-action/init@v1
20
+ with :
21
+ languages : python, cpp
22
+
23
+ - name : Install Ninja
24
+ run : |
25
+ sudo apt-get update -y
26
+ sudo apt-get install -y ninja-build
27
+
28
+ - name : Update submodules
29
+ run : git submodule update --init --recursive
30
+
31
+ - name : Install Torch
32
+ run : |
33
+ python -m pip install cmake
34
+ python -m pip install torch==1.8.1+cpu -f https://download.pytorch.org/whl/torch_stable.html
35
+ sudo ln -s /usr/bin/ninja /usr/bin/ninja-build
36
+
37
+ - name : Build TorchVision
38
+ run : python setup.py develop --user
39
+
40
+ # If any code scanning alerts are found, they will be under Security -> CodeQL
41
+ # Link: https://github.com/pytorch/vision/security/code-scanning
42
+ - name : Perform CodeQL Analysis
43
+ uses : github/codeql-action/analyze@v1
You can’t perform that action at this time.
0 commit comments