Fix memory-service: remove manual id assignment for auto-increment PK

This commit is contained in:
JC Beasley
2026-07-04 17:05:27 -07:00
parent cb5e26b561
commit 93b21a8164
10 changed files with 186 additions and 19 deletions
+43
View File
@@ -0,0 +1,43 @@
#!/bin/bash
# Get tokens
VAULT_TOKEN=$(curl -sk -X POST -d '{"role_id":"75d2dcfb-9c65-7f60-59b4-eee8c7f8dc0e","secret_id":"6202b465-2f25-547c-ec07-f47cfc4dda3e"}' https://beavault.beawit.net:8200/v1/auth/approle/login | jq -r '.auth.client_token')
NOCODB_TOKEN=$(curl -sk -H "X-Vault-Token: $VAULT_TOKEN" https://beavault.beawit.net:8200/v1/kv/data/api/infrastructure | jq -r '.data.data["nocodb-token"]')
echo "Updating severity column..."
# Update severity column (ID: cv1al80v3ejvij0)
curl -s -X PATCH "http://192.168.25.5:8080/api/v2/meta/columns/cv1al80v3ejvij0" \
-H "xc-token: $NOCODB_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"dtxp": "error,warning,auto-correct",
"meta": {
"options": [
{"title": "error", "color": "#FF0000"},
{"title": "warning", "color": "#FFA500"},
{"title": "auto-correct", "color": "#FFFF00"}
]
}
}'
echo ""
echo "Updating status column..."
# Update status column (ID: cxbxnyh03nkvd0a)
curl -s -X PATCH "http://192.168.25.5:8080/api/v2/meta/columns/cxbxnyh03nkvd0a" \
-H "xc-token: $NOCODB_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"dtxp": "active,reversed,deprecated",
"meta": {
"options": [
{"title": "active", "color": "#00FF00"},
{"title": "reversed", "color": "#FFA500"},
{"title": "deprecated", "color": "#808080"}
]
}
}'
echo ""
echo "Done!"