Skip to content

Commit e6a36b0

Browse files
committed
Merge branch 'develop' into main
2 parents 7efc5e7 + b93b10d commit e6a36b0

File tree

21 files changed

+607
-375
lines changed

21 files changed

+607
-375
lines changed

.github/workflows/pipeline.yaml

Lines changed: 50 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -24,22 +24,26 @@ env:
2424
NODE_VERSION: 18.16.0
2525
# https://github.com/helm/helm/releases
2626
HELM_VERSION: 3.11.2
27+
# https://npmjs.com/package/snyk?activeTab=versions
28+
SNYK_VERSION: 1.1187.0
29+
# https://github.com/oras-project/oras/releases
30+
ORAS_VERSION: 1.0.0
2731

2832
jobs:
2933
sast-creds:
3034
name: SAST - Credentials
3135
runs-on: ubuntu-22.04
3236
steps:
3337
- name: Checkout
34-
uses: actions/checkout@v3.5.2
38+
uses: actions/checkout@v3.5.3
3539
with:
3640
# We need all Git history for testing credentials
3741
fetch-depth: 0
3842
# Ensure all submodules up-to-date
3943
submodules: recursive
4044

4145
- name: SAST - Credentials
42-
uses: trufflesecurity/trufflehog@v3.33.0
46+
uses: trufflesecurity/trufflehog@v3.44.0
4347
with:
4448
base: ${{ github.event.repository.default_branch }}
4549
head: HEAD
@@ -53,7 +57,7 @@ jobs:
5357
runs-on: ubuntu-22.04
5458
steps:
5559
- name: Checkout
56-
uses: actions/checkout@v3.5.2
60+
uses: actions/checkout@v3.5.3
5761
with:
5862
# We need all Git history for "version.sh"
5963
fetch-depth: 0
@@ -73,7 +77,7 @@ jobs:
7377

7478
# Required for running "npx" CLI
7579
- name: Setup Node
76-
uses: actions/setup-node@v3.6.0
80+
uses: actions/setup-node@v3.7.0
7781
with:
7882
node-version: ${{ env.NODE_VERSION }}
7983

@@ -112,20 +116,10 @@ jobs:
112116
--severity-threshold=medium \
113117
.helm-template
114118
115-
# Fix issue "Error: Code Scanning could not process the submitted SARIF file: rejecting SARIF, as there are more runs than allowed (XX > 20)"
116-
# See: https://github.com/github/codeql-action/issues/220
117-
- name: Merge SARIF files
118-
run: |
119-
npx --yes @microsoft/sarif-multitool@${{ env.SARIF_MULTITOOL_VERSION }} \
120-
merge \
121-
--merge-runs \
122-
--output-file merged.sarif \
123-
snyk.sarif
124-
125119
- name: Upload results to GitHub Security
126-
uses: github/codeql-action/upload-sarif@v2.2.12
120+
uses: github/codeql-action/upload-sarif@v2.20.3
127121
with:
128-
sarif_file: merged.sarif
122+
sarif_file: snyk.sarif
129123

130124
deploy-helm:
131125
name: Deploy Helm chart
@@ -137,7 +131,7 @@ jobs:
137131
runs-on: ubuntu-22.04
138132
steps:
139133
- name: Checkout
140-
uses: actions/checkout@v3.5.2
134+
uses: actions/checkout@v3.5.3
141135
with:
142136
# Chart Releaser needs to have local access to "gh-pages" plus current branch
143137
fetch-depth: 0
@@ -177,7 +171,7 @@ jobs:
177171
src: [conversation-api, conversation-ui]
178172
steps:
179173
- name: Checkout
180-
uses: actions/checkout@v3.5.2
174+
uses: actions/checkout@v3.5.3
181175
with:
182176
# We need all Git history for "version.sh"
183177
fetch-depth: 0
@@ -197,31 +191,31 @@ jobs:
197191
198192
- name: Setup QEMU
199193
id: setup-qemu
200-
uses: docker/setup-qemu-action@v2.1.0
194+
uses: docker/setup-qemu-action@v2.2.0
201195
with:
202196
platforms: ${{ env.CONTAINER_PLATFORMS }}
203197

204198
- name: Setup Docker Buildx
205-
uses: docker/setup-buildx-action@v2.5.0
199+
uses: docker/setup-buildx-action@v2.9.1
206200
with:
207201
version: v${{ env.BUILDX_VERSION }}
208202

209203
# Required for running "npx" CLI
210204
- name: Setup Node
211-
uses: actions/setup-node@v3.6.0
205+
uses: actions/setup-node@v3.7.0
212206
with:
213207
node-version: ${{ env.NODE_VERSION }}
214208

215209
- name: Login to container registry
216-
uses: docker/login-action@v2.1.0
210+
uses: docker/login-action@v2.2.0
217211
with:
218212
registry: ${{ env.CONTAINER_REGISTRY }}
219213
username: ${{ github.actor }}
220214
password: ${{ secrets.GITHUB_TOKEN }}
221215

222216
- name: Container meta
223217
id: meta
224-
uses: docker/metadata-action@v4.4.0
218+
uses: docker/metadata-action@v4.6.0
225219
with:
226220
images: ${{ env.CONTAINER_REGISTRY }}/${{ env.CONTAINER_NAME }}/${{ matrix.src }}
227221
tags: |
@@ -244,7 +238,7 @@ jobs:
244238
echo "tag=$tag" >> $GITHUB_OUTPUT
245239
246240
- name: Build/push container
247-
uses: docker/build-push-action@v4.0.0
241+
uses: docker/build-push-action@v4.1.1
248242
with:
249243
build-args: |
250244
VERSION=${{ steps.version.outputs.version_full }}
@@ -275,20 +269,10 @@ jobs:
275269
--severity-threshold=medium \
276270
${{ steps.tag.outputs.tag }}
277271
278-
# Fix issue "Error: Code Scanning could not process the submitted SARIF file: rejecting SARIF, as there are more runs than allowed (XX > 20)"
279-
# See: https://github.com/github/codeql-action/issues/220
280-
- name: Merge SARIF files
281-
run: |
282-
npx --yes @microsoft/sarif-multitool@${{ env.SARIF_MULTITOOL_VERSION }} \
283-
merge \
284-
--merge-runs \
285-
--output-file merged.sarif \
286-
snyk.sarif
287-
288272
- name: Upload results to GitHub Security
289-
uses: github/codeql-action/upload-sarif@v2.2.12
273+
uses: github/codeql-action/upload-sarif@v2.20.3
290274
with:
291-
sarif_file: merged.sarif
275+
sarif_file: snyk.sarif
292276

293277
sast-semgrep:
294278
name: SAST - Semgrep
@@ -300,7 +284,7 @@ jobs:
300284
image: returntocorp/semgrep
301285
steps:
302286
- name: Checkout
303-
uses: actions/checkout@v3.5.2
287+
uses: actions/checkout@v3.5.3
304288

305289
- name: Run tests
306290
# Semgrep can be used to break the build when it detects security issues. In this case we want to upload the issues to GitHub Security
@@ -310,6 +294,34 @@ jobs:
310294
run: semgrep ci --sarif --output=semgrep.sarif
311295

312296
- name: Upload results to GitHub Security
313-
uses: github/codeql-action/upload-sarif@v2.2.12
297+
uses: github/codeql-action/upload-sarif@v2.20.3
314298
with:
315299
sarif_file: semgrep.sarif
300+
301+
deploy-artifacthub-metadata:
302+
name: Deploy ArtifactHub metadata
303+
# Only deploy on main branch, as we don't want to break verification with a bad metadata file during development
304+
if: github.ref == 'refs/heads/main'
305+
runs-on: ubuntu-22.04
306+
steps:
307+
- name: Checkout
308+
uses: actions/checkout@v3.5.3
309+
310+
- name: Setup ORAS
311+
uses: oras-project/setup-oras@v1.0.0
312+
with:
313+
version: ${{ env.ORAS_VERSION }}
314+
315+
- name: Login to registry
316+
uses: docker/login-action@v2.2.0
317+
with:
318+
registry: ${{ env.CONTAINER_REGISTRY }}
319+
username: ${{ github.actor }}
320+
password: ${{ secrets.GITHUB_TOKEN }}
321+
322+
- name: Push to registry
323+
run: |
324+
oras push \
325+
${{ env.CONTAINER_REGISTRY }}/${{ env.CONTAINER_NAME }}:artifacthub.io \
326+
artifacthub-repo.yml:application/vnd.cncf.artifacthub.repository-metadata.layer.v1.yaml \
327+
--config /dev/null:application/vnd.cncf.artifacthub.config.v1+yaml

CODE_OF_CONDUCT.md

Lines changed: 83 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,83 @@
1+
# Contributor Covenant Code of Conduct
2+
3+
## Our Pledge
4+
5+
We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, caste, color, religion, or sexual identity and orientation.
6+
7+
We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
8+
9+
## Our Standards
10+
11+
Examples of behavior that contributes to a positive environment for our community include:
12+
13+
- Demonstrating empathy and kindness toward other people
14+
- Being respectful of differing opinions, viewpoints, and experiences
15+
- Giving and gracefully accepting constructive feedback
16+
- Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience
17+
- Focusing on what is best not just for us as individuals, but for the overall community
18+
19+
Examples of unacceptable behavior include:
20+
21+
- The use of sexualized language or imagery, and sexual attention or advances of any kind
22+
- Trolling, insulting or derogatory comments, and personal or political attacks
23+
- Public or private harassment
24+
- Publishing others' private information, such as a physical or email address, without their explicit permission
25+
- Other conduct which could reasonably be considered inappropriate in a professional setting
26+
27+
## Enforcement Responsibilities
28+
29+
Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful.
30+
31+
Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate.
32+
33+
## Scope
34+
35+
This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event.
36+
37+
## Enforcement
38+
39+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at [Clémence Lesné](mailto:clemlesne@users.noreply.github.com). All complaints will be reviewed and investigated promptly and fairly.
40+
41+
All community leaders are obligated to respect the privacy and security of the reporter of any incident.
42+
43+
## Enforcement Guidelines
44+
45+
Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct:
46+
47+
### 1. Correction
48+
49+
**Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community.
50+
51+
**Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested.
52+
53+
### 2. Warning
54+
55+
**Community Impact**: A violation through a single incident or series of actions.
56+
57+
**Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban.
58+
59+
### 3. Temporary Ban
60+
61+
**Community Impact**: A serious violation of community standards, including sustained inappropriate behavior.
62+
63+
**Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban.
64+
65+
### 4. Permanent Ban
66+
67+
**Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals.
68+
69+
**Consequence**: A permanent ban from any sort of public interaction within the community.
70+
71+
## Attribution
72+
73+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.1, available at [https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
74+
75+
Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder][Mozilla CoC].
76+
77+
For answers to common questions about this code of conduct, see the FAQ at [https://www.contributor-covenant.org/faq][FAQ]. Translations are available at [https://www.contributor-covenant.org/translations][translations].
78+
79+
[homepage]: https://www.contributor-covenant.org
80+
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
81+
[Mozilla CoC]: https://github.com/mozilla/diversity
82+
[FAQ]: https://www.contributor-covenant.org/faq
83+
[translations]: https://www.contributor-covenant.org/translations

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# 🔒 Private GPT
1+
# Employee communication with Private GPT – AI-powered chatbot you can trust
22

33
> 👋🏻 Demo available at [private-gpt.shopping-cart-devops-demo.lesne.pro](https://private-gpt.shopping-cart-devops-demo.lesne.pro).
44
@@ -153,4 +153,12 @@ sequenceDiagram
153153

154154
WIP
155155

156+
## [Security](./SECURITY.md)
157+
158+
## Support
159+
160+
This project is open source and maintained by people like you. If you need help or found a bug, please feel free to open an issue on the [clemlesne/private-gpt](https://github.com/clemlesne/private-gpt) GitHub project.
161+
162+
## [Code of conduct](./CODE_OF_CONDUCT.md)
163+
156164
## [Authors](./AUTHORS.md)

SECURITY.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Security Policy
2+
3+
## Proactive detection of vulnerabilities
4+
5+
At each build, a vulnerability scan is performed on the system. If a vulnerability that can be upgraded is detected, the build is stopped and the image is not pushed to the registry. Vulnerability is reported in [GitHub Security](https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/about-code-scanning). The maintainers are alterted and have access to reports.
6+
7+
Automation is supported by [Snyk](https://snyk.io) and [Semgrep](https://semgrep.dev). Helm chart, configuration files, and containers, are scanned for vulnerabilities and misconfigurations.
8+
9+
## Reporting a vulnerability
10+
11+
If you think you have found a vulnerability, please do not open an issue on GitHub. Instead, please send an email to [Clémence Lesné](mailto:clemence@lesne.pro).
12+
13+
## Chain of trust
14+
15+
Helm chart and containers are not signed yet with a GPG key.
16+
17+
## Reliability notes
18+
19+
Systems are built every days. Each image is accompanied by a SBOM (Software Bill of Materials) which allows to verify that the installed packages are those expected. This speed has the advantage of minimizing exposure to security flaws, which will then be corrected on the build environments in 24 hours.
20+
21+
Nevertheless it can happen that a package provider (e.g. Debian, Canonical, Red Hat) deploys a system update that introduces a bug. This is difficult to predict.

artifacthub-repo.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
repositoryID: 06ff1e13-8ff5-42a2-b081-0d647a731827
2+
owners:
3+
- name: clemlesne
4+
email: clemlesne@users.noreply.github.com

cicd/helm/private-gpt/Chart.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,22 @@ name: private-gpt
22
description: Private GPT is a local version of Chat GPT, using Azure OpenAI.
33
version: 0.0.0
44
apiVersion: v1
5+
keywords:
6+
- ai-assisted-chat
7+
- azure-openai
8+
- business-productivity
9+
- chatgpt
10+
- cloud-based-chat
11+
- conversational-interface
12+
- deploy-chatbot
13+
- employee-communication
14+
- employee-engagement
15+
- enterprise-grade-platform
16+
- internal-communication
17+
- local-chatbot
18+
- natural-language-processing
19+
- private-gpt
20+
- virtual-assistant-for-employees
521
dependencies:
622
- name: qdrant
723
version: 0.2.9

docs/doc.png

26.8 KB
Loading

0 commit comments

Comments
 (0)