-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 933318f
Showing
47 changed files
with
4,149 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
**/__pycache__ | ||
**/.venv | ||
**/.classpath | ||
**/.dockerignore | ||
**/.env | ||
**/.git | ||
**/.gitignore | ||
**/.project | ||
**/.settings | ||
**/.toolstarget | ||
**/.vs | ||
**/.vscode | ||
**/*.*proj.user | ||
**/*.dbmdl | ||
**/*.jfm | ||
**/bin | ||
**/charts | ||
**/docker-compose* | ||
**/compose* | ||
**/Dockerfile* | ||
**/node_modules | ||
**/npm-debug.log | ||
**/obj | ||
**/secrets.dev.yaml | ||
**/values.dev.yaml | ||
**/.nox | ||
LICENSE | ||
.history |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
LOG_LEVEL=DEBUG | ||
DIAL_URL=DIAL_URL |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
[flake8] | ||
# E501 string literal is too long | ||
# W503 line break before binary operator | ||
# E203 whitespace before ':' (triggered on list slices like xs[i : i + 5]) | ||
ignore = E501, W503, E203 | ||
exclude = | ||
.git, | ||
.tmp, | ||
.venv, | ||
.conda, | ||
.nox, | ||
.pytest_cache | ||
__pycache__, | ||
__init__.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
* @adubovik | ||
/.github/ @nepalevov @alexey-ban |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
blank_issues_enabled: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
version: 2 | ||
updates: | ||
- package-ecosystem: "pip" | ||
directory: "/" | ||
schedule: | ||
interval: "weekly" | ||
day: "wednesday" | ||
time: "09:00" | ||
# Disable version updates, keep security updates only | ||
open-pull-requests-limit: 0 | ||
commit-message: | ||
# Prefix all commit messages with "chore: " | ||
prefix: "chore" | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: "weekly" | ||
day: "wednesday" | ||
time: "09:00" | ||
commit-message: | ||
# Prefix all commit messages with "chore: " | ||
prefix: "chore" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: "Validate PR title" | ||
|
||
on: | ||
pull_request_target: | ||
types: | ||
- opened | ||
- edited | ||
- synchronize | ||
|
||
jobs: | ||
pr-title-check: | ||
uses: epam/ai-dial-ci/.github/workflows/[email protected] | ||
secrets: | ||
ACTIONS_BOT_TOKEN: ${{ secrets.ACTIONS_BOT_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
name: PR Workflow | ||
|
||
on: | ||
pull_request: | ||
branches: [development, release-*] | ||
|
||
jobs: | ||
run_tests: | ||
uses: epam/ai-dial-ci/.github/workflows/[email protected] | ||
secrets: inherit | ||
with: | ||
python_version: 3.8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
name: Release Workflow | ||
|
||
on: | ||
push: | ||
branches: [development, release-*] | ||
|
||
jobs: | ||
release: | ||
uses: epam/ai-dial-ci/.github/workflows/[email protected] | ||
secrets: inherit | ||
with: | ||
python_version: 3.8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: Slash Command Dispatch | ||
on: | ||
issue_comment: | ||
types: [created] | ||
jobs: | ||
slashCommandDispatch: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Slash Command Dispatch | ||
id: scd | ||
uses: peter-evans/slash-command-dispatch@13bc09769d122a64f75aa5037256f6f2d78be8c4 # v4.0.0 | ||
with: | ||
token: ${{ secrets.ACTIONS_BOT_TOKEN }} | ||
reaction-token: ${{ secrets.ACTIONS_BOT_TOKEN }} | ||
config: > | ||
[ | ||
{ | ||
"command": "deploy-review", | ||
"permission": "write", | ||
"issue_type": "pull-request", | ||
"repository": "epam/ai-dial-ci", | ||
"static_args": [ | ||
"application=${{ github.event.repository.name }}" | ||
] | ||
} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
.DS_Store | ||
venv | ||
.venv | ||
.env | ||
.history | ||
.idea | ||
__pycache__ | ||
.nox | ||
dist | ||
.vscode/launch.json | ||
.pytest_cache | ||
core-data | ||
core-logs | ||
config.json | ||
~* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"recommendations": [ | ||
"ms-python.python", | ||
"ms-python.black-formatter", | ||
"ms-python.isort" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"files.trimTrailingWhitespace": true, | ||
"[python]": { | ||
"editor.defaultFormatter": "ms-python.black-formatter", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.organizeImports": "explicit" | ||
}, | ||
"editor.tabSize": 4 | ||
}, | ||
"python.testing.pytestArgs": ["."], | ||
"python.testing.unittestEnabled": false, | ||
"python.testing.pytestEnabled": true, | ||
"python.analysis.typeCheckingMode": "basic" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# How to contribute | ||
|
||
As an open-source project in a rapidly developing field, we are open to contributions, whether it be in the form of a new feature, improved infrastructure, or better documentation. | ||
|
||
For detailed information on how to contribute, see the full [contributing documentation](https://github.com/epam/ai-dial/blob/main/CONTRIBUTING.md). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
FROM python:3.11-alpine as builder | ||
|
||
RUN apk update && apk upgrade --no-cache libcrypto3 libssl3 | ||
RUN apk add --no-cache alpine-sdk linux-headers | ||
RUN pip install poetry | ||
|
||
WORKDIR /app | ||
|
||
# Install split into two steps (the dependencies and the sources) | ||
# in order to leverage the Docker caching | ||
COPY pyproject.toml poetry.lock poetry.toml ./ | ||
RUN poetry install --no-interaction --no-ansi --no-cache --no-root --no-directory --only main | ||
|
||
COPY . . | ||
RUN poetry install --no-interaction --no-ansi --no-cache --only main | ||
|
||
FROM python:3.11-alpine as server | ||
|
||
RUN apk update && apk upgrade --no-cache libcrypto3 libssl3 | ||
|
||
# fix CVE-2023-52425 | ||
RUN apk upgrade --no-cache libexpat | ||
|
||
WORKDIR /app | ||
|
||
# Copy the sources and virtual env. No poetry. | ||
RUN adduser -u 1001 --disabled-password --gecos "" appuser | ||
COPY --chown=appuser --from=builder /app . | ||
|
||
COPY ./scripts/docker_entrypoint.sh /docker_entrypoint.sh | ||
RUN chmod +x /docker_entrypoint.sh | ||
|
||
EXPOSE 5000 | ||
|
||
USER appuser | ||
ENTRYPOINT ["/docker_entrypoint.sh"] | ||
|
||
CMD uvicorn aidial_adapter_dial.app:app --host 0.0.0.0 --port 5000 --timeout-keep-alive ${TIMEOUT_KEEP_ALIVE:-5} |
Oops, something went wrong.