Windows installer: payload hash-locking, SBOM, client-IP handling, operator docs
This commit is contained in:
@@ -13,10 +13,10 @@ This guide documents the process for migrating data from the legacy VBScript Sho
|
||||
### New System (Flask)
|
||||
- Core `assets` table (unified asset registry)
|
||||
- Plugin-specific extension tables:
|
||||
- `equipment` (equipmenttypeid → equipmenttypes)
|
||||
- `computers` (computertypeid → computertypes)
|
||||
- `printers` (printertypeid → printertypes)
|
||||
- `network_device` (networkdevicetypeid → networkdevicetypes)
|
||||
- `equipment` (equipmenttypeid -> equipmenttypes)
|
||||
- `computers` (computertypeid -> computertypes)
|
||||
- `printers` (printertypeid -> printertypes)
|
||||
- `network_device` (networkdevicetypeid -> networkdevicetypes)
|
||||
|
||||
## Key Mappings
|
||||
|
||||
|
||||
@@ -4,27 +4,12 @@ from logging.config import fileConfig
|
||||
from flask import current_app
|
||||
|
||||
from alembic import context
|
||||
from sqlalchemy.ext.compiler import compiles
|
||||
from sqlalchemy.schema import CreateTable
|
||||
|
||||
|
||||
# Force every table the migrations create on MySQL to utf8mb4 + DYNAMIC row
|
||||
# format. Without this a fresh `flask db upgrade` inherits the server default
|
||||
# charset, so a box whose default is latin1 (common on older MySQL) silently
|
||||
# builds a latin1 schema that drifts from the utf8mb4 production target. The
|
||||
# DYNAMIC row format also keeps utf8mb4 indexes under the 767-byte prefix limit
|
||||
# on pre-5.7 InnoDB. Scoped to the mysql dialect so the SQLite test DB is
|
||||
# untouched.
|
||||
@compiles(CreateTable, "mysql")
|
||||
def _mysql_create_table_utf8mb4(element, compiler, **kw):
|
||||
sql = compiler.visit_create_table(element, **kw)
|
||||
if "CHARSET" not in sql.upper():
|
||||
sql = sql.rstrip().rstrip(";")
|
||||
sql += (
|
||||
" ENGINE=InnoDB DEFAULT CHARSET=utf8mb4"
|
||||
" COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC"
|
||||
)
|
||||
return sql
|
||||
# Registers the compiler hook that forces utf8mb4 + DYNAMIC on MySQL. Imported
|
||||
# for the side effect, and shared with the PLUGIN chains via
|
||||
# shopdb/plugins/alembic_template.py - it used to live here, so it covered core
|
||||
# only and plugin baselines inherited the server default charset.
|
||||
import shopdb.utils.mysql_charset # noqa: F401
|
||||
|
||||
# this is the Alembic Config object, which provides
|
||||
# access to the values within the .ini file in use.
|
||||
|
||||
Reference in New Issue
Block a user