Skip to content

Commit 9980110

Browse files
authored
Merge branch 'master' into snyk-upgrade-edef568ec0c8f0b6ffd781bba6e2d963
2 parents ad45dea + d2c333e commit 9980110

File tree

7 files changed

+197
-22
lines changed

7 files changed

+197
-22
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# This workflow checks out code, builds an image, performs a container image
2+
# vulnerability scan with Anchore's Grype tool, and integrates the results with GitHub Advanced Security
3+
# code scanning feature. For more information on the Anchore scan action usage
4+
# and parameters, see https://github.com/anchore/scan-action. For more
5+
# information on Anchore's container image scanning tool Grype, see
6+
# https://github.com/anchore/grype
7+
name: Anchore Container Scan
8+
on: push
9+
jobs:
10+
Anchore-Build-Scan:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout the code
14+
uses: actions/checkout@v2
15+
- name: Build the Docker image
16+
run: docker build . --file Dockerfile --tag localbuild/testimage:latest
17+
- name: Run the Anchore scan action itself with GitHub Advanced Security code scanning integration enabled
18+
uses: anchore/scan-action@main
19+
with:
20+
image: "localbuild/testimage:latest"
21+
acs-report-enable: true
22+
- name: Upload Anchore Scan Report
23+
uses: github/codeql-action/upload-sarif@v1
24+
with:
25+
sarif_file: results.sarif
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
# For most projects, this workflow file will not need changing; you simply need
2+
# to commit it to your repository.
3+
#
4+
# You may wish to alter this file to override the set of languages analyzed,
5+
# or to provide custom queries or build logic.
6+
#
7+
# ******** NOTE ********
8+
# We have attempted to detect the languages in your repository. Please check
9+
# the `language` matrix defined below to confirm you have the correct set of
10+
# supported CodeQL languages.
11+
#
12+
name: "CodeQL"
13+
14+
on:
15+
push:
16+
branches: [ master ]
17+
pull_request:
18+
# The branches below must be a subset of the branches above
19+
branches: [ master ]
20+
schedule:
21+
- cron: '24 1 * * 1'
22+
23+
jobs:
24+
analyze:
25+
name: Analyze
26+
runs-on: ubuntu-latest
27+
28+
strategy:
29+
fail-fast: false
30+
matrix:
31+
language: [ 'javascript' ]
32+
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
33+
# Learn more:
34+
# https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed
35+
36+
steps:
37+
- name: Checkout repository
38+
uses: actions/checkout@v2
39+
40+
# Initializes the CodeQL tools for scanning.
41+
- name: Initialize CodeQL
42+
uses: github/codeql-action/init@v1
43+
with:
44+
languages: ${{ matrix.language }}
45+
# If you wish to specify custom queries, you can do so here or in a config file.
46+
# By default, queries listed here will override any specified in a config file.
47+
# Prefix the list here with "+" to use these queries and those in the config file.
48+
# queries: ./path/to/local/query, your-org/your-repo/queries@main
49+
50+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
51+
# If this step fails, then you should remove it and run the build manually (see below)
52+
- name: Autobuild
53+
uses: github/codeql-action/autobuild@v1
54+
55+
# ℹ️ Command-line programs to run using the OS shell.
56+
# 📚 https://git.io/JvXDl
57+
58+
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
59+
# and modify them (or add more) to build your code if your project
60+
# uses a compiled language
61+
62+
#- run: |
63+
# make bootstrap
64+
# make release
65+
66+
- name: Perform CodeQL Analysis
67+
uses: github/codeql-action/analyze@v1
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# This workflow requires that you have an existing account with codescan.io
2+
# For more information about configuring your workflow,
3+
# read our documentation at https://github.com/codescan-io/codescan-scanner-action
4+
name: CodeScan
5+
6+
on:
7+
push:
8+
branches: [ master ]
9+
pull_request:
10+
# The branches below must be a subset of the branches above
11+
branches: [ master ]
12+
13+
jobs:
14+
CodeScan:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout repository
18+
uses: actions/checkout@v2
19+
- name: Cache files
20+
uses: actions/cache@v2
21+
with:
22+
path: |
23+
~/.sonar
24+
key: ${{ runner.os }}-sonar
25+
restore-keys: ${{ runner.os }}-sonar
26+
- name: Run Analysis
27+
uses: codescan-io/codescan-scanner-action@master
28+
with:
29+
login: ${{ secrets.CODESCAN_AUTH_TOKEN }}
30+
organization: ${{ secrets.CODESCAN_ORGANIZATION_KEY }}
31+
projectKey: ${{ secrets.CODESCAN_PROJECT_KEY }}
32+
- name: Upload SARIF file
33+
uses: github/codeql-action/upload-sarif@v1
34+
with:
35+
sarif_file: codescan.sarif
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# A sample workflow which checks out the code, builds a container
2+
# image using Docker and scans that image for vulnerabilities using
3+
# Snyk. The results are then uploaded to GitHub Security Code Scanning
4+
#
5+
# For more examples, including how to limit scans to only high-severity
6+
# issues, monitor images for newly disclosed vulnerabilities in Snyk and
7+
# fail PR checks for new vulnerabilities, see https://github.com/snyk/actions/
8+
9+
name: Snyk Container
10+
on: push
11+
jobs:
12+
snyk:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v2
16+
- name: Build a Docker image
17+
run: docker build -t your/image-to-test .
18+
- name: Run Snyk to check Docker image for vulnerabilities
19+
# Snyk can be used to break the build when it detects vulnerabilities.
20+
# In this case we want to upload the issues to GitHub Code Scanning
21+
continue-on-error: true
22+
uses: snyk/actions/docker@master
23+
env:
24+
# In order to use the Snyk Action you will need to have a Snyk API token.
25+
# More details in https://github.com/snyk/actions#getting-your-snyk-token
26+
# or you can signup for free at https://snyk.io/login
27+
SNYK_TOKEN: ${{ secrets.SNYK_TOKEN }}
28+
with:
29+
image: your/image-to-test
30+
args: --file=Dockerfile
31+
- name: Upload result to GitHub Code Scanning
32+
uses: github/codeql-action/upload-sarif@v1
33+
with:
34+
sarif_file: snyk.sarif

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33

44

5-
Tech used :
5+
Tech used:
66
<br/>. 🧩.Nginx- To act as my production server.
77
<br/>. 🌐 Docker - To containerize my app and production server.
88
<br/>. 🙎‍♂️ Chatbot - To educate users who arent familiar with polls

client/package-lock.json

Lines changed: 28 additions & 18 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

client/package.json

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"@testing-library/jest-dom": "^4.2.4",
77
"@testing-library/react": "^9.5.0",
88
"@testing-library/user-event": "^7.2.1",
9-
"axios": "0.20.0",
9+
"axios": "0.21.0",
1010
"bootstrap": "^4.5.3",
1111
"bootstrap-sass": "^3.4.1",
1212
"font-awesome": "^4.7.0",
@@ -19,7 +19,11 @@
1919
"react": "^16.14.0",
2020
"react-avatar": "^3.9.7",
2121
"react-bootstrap": "^1.4.0",
22+
2223
"react-bootstrap-icons": "^1.0.3-alpha5",
24+
25+
"react-bootstrap-icons": "^1.1.0",
26+
2327
"react-bs-datatable": "^2.1.1",
2428

2529
"react-confirm-alert": "^2.6.2",
@@ -37,15 +41,15 @@
3741
"react-dom": "^16.14.0",
3842
"react-moment": "^0.9.7",
3943
"react-notifications": "^1.7.2",
40-
"react-redux": "^7.2.1",
44+
"react-redux": "^7.2.2",
4145
"react-router-dom": "^5.2.0",
4246
"react-scripts": "^3.4.4",
4347
"react-simple-chatbot": "^0.6.1",
4448
"react-spinners": "^0.9.0",
4549
"react-text-loop": "^2.3.0",
4650
"redux": "^4.0.5",
4751
"redux-thunk": "^2.3.0",
48-
"styled-components": "^5.2.0"
52+
"styled-components": "^5.2.1"
4953
},
5054
"scripts": {
5155
"start": "react-scripts start",

0 commit comments

Comments
 (0)