MYCSS

2023-12-21

Ось і закінчився модуль навчання з #GoIT #Python #WEB 15. Груповий проєкт на #FastAPI.

Ось і закінчився модуль навчання з #GoIT #Python #WEB 15.
Сьогодні, 2023.12.21, був захист курсових проєктів.
Дякую моїй команді котра складалася з 4-х розробників за нашу спільну роботу за останні два тижні.
Ось частина нашого групового проєкту на #FastAPI.

Команда:

  1. Team Lead: Sasha Danylenko - https://www.linkedin.com/in/sasha-danylenko-9a7a0b287/
  2. Scrum Master: Oleksander Borovyk - https://www.linkedin.com/in/oleksander-borovyk/
  3. Developer: Oleksii Hladkov - https://www.linkedin.com/in/oleksii-hladkov/
  4. Developer: Lex Xai🐍 - https://www.linkedin.com/in/lexxai/





2023-12-04

Нотатка: Python. Django framework. ORM "GROUP BY". SQLite.

Django SQL GROUP BY.

А Ви знали що його не має в ORM у прямому вигляді ?
SELECT x.* FROM logs x WHERE x.username = 'user1' GROUP BY x.host

DBeaver тестування

Є таблиця log доступу користувачів:

CREATE TABLE logs (
	id INTEGER PRIMARY KEY AUTOINCREMENT,
	date DATETIME,
	host VARCHAR,
	request VARCHAR,
	username VARCHAR
);

CREATE INDEX logs_host_IDX ON logs (host);
SEED LOG TABLE

Стала проста задача для SQL запиту. Для отримання унікальних записів IP адрес з яких отримував доступ певний користувач.

2023-12-03

Закінчення курсу Python Web. 14 моїх домашніх завдань.

Shcool GoIT. Course: Python Web. Homework.

https://github.com/lexxai/goit_python_web_homework

Нотатка: патч порту сервера NGINX для додавання модуля JWT AUTH. Платформа FreeBSD.

Постала задача як зробити просту автентифікацію за JWT токеном безпосередньо через NGINX сервер.

За підпискою NGINX PLUS jwt-auth є у базовому комплекті. У Community verision jwt-auth не має.

Знайшов модуль від автора nginx-auth-jwt  і вирішив додати до FreeBSD порту пакетів, щоб надалі було зручно собі оновлювати.

Результат оформив собі до репозиторію : https://github.com/lexxai/port_nginx_add_jwt_auth.

nginx hwt-auth FreeBSD port 3rd party module

Приклад використання nginx.conf:

load_module /usr/local/libexec/nginx/ngx_http_auth_jwt_module.so;

...
	location /token_protected {
		auth_jwt "closed site";
		auth_jwt_key_file .jwt_keyfile.json keyval;
		auth_jwt_validate_exp on;
		auth_jwt_validate_iat on;
		auth_jwt_validate_sig on;
		auth_jwt_validate_sub on;
		....



2023-09-22

Сертифікат : Google IT Google IT Automationwith Python - Full Course Completed

Сертифікат : Google IT Google IT Automationwith Python - Full Course Completed on Sep 20, 2023

 

Google IT Automation with Python Specialization

Google IT Automation Certificate - Credly

Google IT Automation with Python 

This six-course certificate, developed by Google, is designed to provide IT professionals with in-demand skills -- including Python, Git, and IT automation -- that can help them advance their careers. The hands-on curriculum is designed to teach learners how to write code in Python, with a special focus on how this applies to automating tasks in the world of IT support and systems administration. Those who received this certificate passed all graded assessments with a score of 80% of above. They should have a strong foundation in how to use Git and GitHub, troubleshoot and debug complex problems, and apply automation at scale by using configuration management and the Cloud in order to prepare them for more advanced IT Support Specialist or Junior Systems Administrator positions. 

2023-09-21

Сертифікат : Google IT Automation with Python Specialization - Configuration Management and the Cloud - Completed on Sep 20, 2023

Ось 5-й курс "Configuration Management and the Cloud" з 6 курсів за напрямком "Google IT Automation with Python Specialization" на платформі Coursera та за підтримки (2022-2023 UA Prometheus)  - успішно завершено - Вересень 2023.

Google IT Automation with Python Specialization - Configuration Management and the Cloud

2023-09-08

Нотатка: pyzbar, pyinstaller, poetry, python - missing lib

При використанні бібліотеки pyzbar, її компоненти не додаються до exe файлу створеного за допомогою pyinstaller.
Ось розв'язання проблеми. У мене середовище: Python 3.11.5 та poetry.
pyinstaller "../some_app/main.py" --clean --name some_app --onefile --version-file "../versionfile.txt" --add-binary "%VIRTUAL_ENV%\Lib\site-packages\pyzbar\*.dll;pyzbar"

EXE файл після цього самодостатнім є, додаткових dll додавати не треба.

Перевірено у Windows Sandbox.

За матеріалами.
Коли забув ти рідну мову, біднієш духом ти щодня...
When you forgot your native language you would become a poor at spirit every day ...

Д.Білоус / D.Bilous
Рабів до раю не пускають. Будь вільним!

ipv6 ready