Files
cloudron-box/migrations/20240716214414-appPortBindings-make-count-not-null.js
Girish Ramakrishnan aeddaa4566 apps: rework portBindings
ports is REST API input . Map of env var to the host port
portBinding is the database structure. Map of env var to host port, count, type etc

also, rename portCount -> count in various places to keep things consistent
2024-07-17 00:25:47 +02:00

10 lines
269 B
JavaScript

'use strict';
exports.up = async function(db) {
await db.runSql('UPDATE appPortBindings SET count=1 WHERE count IS NULL');
await db.runSql('ALTER TABLE appPortBindings MODIFY count INTEGER NOT NULL DEFAULT 1');
};
exports.down = async function(/* db */) {
};