Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/auth_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Installing dependencies
run: |
sudo apt-get update
pip install -r front/requirements.txt
pip install -r front/requirements.lock

- name: Running tests
run: |
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/dependency_review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,5 @@ jobs:
uses: actions/checkout@v4
- name: Dependency Review
uses: actions/dependency-review-action@v4
with:
fail-on-severity: critical
4 changes: 2 additions & 2 deletions .github/workflows/full_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ jobs:

- name: Install dependencies
run: |
sudo python -m pip install pip pytest selenium --ignore-installed urllib3
sudo python -m pip install -r front/requirements.txt --ignore-installed
sudo python -m pip install pip pytest pytest-mock selenium --ignore-installed urllib3
sudo python -m pip install -r front/requirements.lock --ignore-installed

- name: Check availability
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
cache-dependency-path: ${{matrix.node}}/requirements.txt
cache-dependency-path: ${{matrix.node}}/${{ matrix.node == 'front' && 'requirements.lock' || 'requirements.txt' }}

- name: Install dependencies
run: |
Expand All @@ -30,7 +30,7 @@ jobs:
sudo apt-get install -y --no-install-recommends mininet
mkdir -p /opt/mininet_dependencies
fi
pip install -r ${{matrix.node}}/requirements.txt
pip install -r ${{matrix.node}}/${{ matrix.node == 'front' && 'requirements.lock' || 'requirements.txt' }}

- name: Lint with mypy
run: |
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,6 @@ back/rabbitmq/rabbitmq/
.env
*.log
*.ini
front/rabbitmq/rabbitmq
front/rabbitmq/rabbitmq
front/src/static/dist/
front/web/node_modules/
4 changes: 3 additions & 1 deletion front/.dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,6 @@ src/static/video
src/static/pcaps
src/static/assets
src/static/avatar
src/static/quiz_images
src/static/quiz_images
src/static/dist
web/node_modules
1 change: 1 addition & 0 deletions front/.python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.11
20 changes: 16 additions & 4 deletions front/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,17 +1,29 @@
FROM node:22-slim AS web-build

WORKDIR /front
COPY ./web/ /front/web/
COPY ./src/static/netfront/ /front/src/static/netfront/
COPY ./src/static/config_forms/ /front/src/static/config_forms/

WORKDIR /front/web
RUN npm install --no-audit --no-fund --prefer-offline
RUN npm run build

FROM python:3.11

WORKDIR /app
RUN pip install setuptools --upgrade
RUN pip install wheel uwsgi
ADD ./requirements.txt /app/requirements.txt

RUN pip install -r requirements.txt
COPY requirements.lock /app/requirements.lock
RUN pip install --no-cache-dir -r /app/requirements.lock

RUN mkdir -p /app/.postgresql && \
wget "https://storage.yandexcloud.net/cloud-certs/CA.pem" -O /app/.postgresql/root.crt && \
chmod 0600 /app/.postgresql/root.crt

ADD ./src /app

COPY --from=web-build /front/src/static/dist/ /app/static/dist/

ADD run_app.sh /app/run_app.sh
RUN chmod +x /app/run_app.sh

Expand Down
70 changes: 70 additions & 0 deletions front/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
[project]
name = "miminet-front"
version = "0.1.0"
description = "Miminet front-end Flask application."
requires-python = ">=3.11,<3.13"
dependencies = [
"Flask==3.1.2",
"Flask-Admin==2.0.1",
"Flask-Cors==6.0.2",
"Flask-JWT-Extended==4.7.1",
"Flask-Login==0.6.3",
"Flask-Migrate==4.1.0",
"Flask-SQLAlchemy==3.1.1",
"Jinja2==3.1.6",
"Mako>=1.3.11",
"MarkupSafe==3.0.2",
"Pillow==11.3.0",
"PySocks==1.7.1",
"SQLAlchemy==2.0.43",
"Werkzeug==3.1.3",
"alembic==1.16.5",
"beautifulsoup4==4.13.5",
"cachecontrol>=0.14",
"celery==5.5.3",
"certifi==2025.10.5",
"charset-normalizer==3.4.3",
"click==8.1.8",
"colorama==0.4.6",
"dpkt==1.9.8",
"google==3.0.0",
"google-auth==2.40.3",
"google-auth-oauthlib==1.2.2",
"greenlet==3.2.4",
"h11==0.16.0",
"idna==3.10",
"importlib-metadata==8.7.0",
"importlib-resources==6.5.2",
"itsdangerous==2.2.0",
"jsonschema==4.25.1",
"kombu==5.5.4",
"oauthlib==3.3.1",
"psycopg2-binary==2.9.10",
"pyasn1==0.6.1",
"pyasn1-modules==0.4.2",
"python-dateutil==2.9.0.post0",
"python-dotenv==1.1.1",
"requests==2.32.5",
"requests-oauthlib==2.0.0",
"rsa==4.9.1",
"six==1.17.0",
"soupsieve==2.8",
"urllib3==2.5.0",
"uWSGI>=2.0",
"vine==5.1.0",
"wcwidth==0.2.13",
"websocket-client==1.8.0",
"wsproto==1.2.0",
"wtforms==3.2.1",
"zipp==3.23.0",
]

[project.optional-dependencies]
test = [
"pytest==8.4.2",
"pytest-mock==3.15.1",
"selenium",
]

[tool.uv]
package = false
Loading
Loading