Skip to content
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260611202649, Down_20260611202649)
MigrationClient.AddMigration(Up_20260702013055, Down_20260702013055)
}

func Up_20260611202649(tx *sql.Tx) error {
func Up_20260702013055(tx *sql.Tx) error {
// When a Windows MDM configuration profile is deleted, its <Delete> commands cannot be generated until the profile-manager cron
// reconciles the surviving host_mdm_windows_profiles rows, but the SyncML those <Delete> commands are built from lives only on the
// now-deleted definition row. This table retains that content (profile_uuid, team_id, name, syncml) past the logical delete so the
Expand Down Expand Up @@ -44,6 +44,6 @@ func Up_20260611202649(tx *sql.Tx) error {
return nil
}

func Down_20260611202649(tx *sql.Tx) error {
func Down_20260702013055(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260615135619, Down_20260615135619)
MigrationClient.AddMigration(Up_20260702013056, Down_20260702013056)
}

func Up_20260615135619(tx *sql.Tx) error {
func Up_20260702013056(tx *sql.Tx) error {
_, err := tx.Exec(`
CREATE TABLE setup_experience_software_installers (
software_installer_id INT UNSIGNED NOT NULL,
Expand All @@ -28,6 +28,6 @@ CREATE TABLE setup_experience_software_installers (
return nil
}

func Down_20260615135619(tx *sql.Tx) error {
func Down_20260702013056(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
)

func TestUp_20260615135619(t *testing.T) {
func TestUp_20260702013056(t *testing.T) {
db := applyUpToPrev(t)

applyNext(t, db)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260617172853, Down_20260617172853)
MigrationClient.AddMigration(Up_20260702013057, Down_20260702013057)
}

func Up_20260617172853(tx *sql.Tx) error {
func Up_20260702013057(tx *sql.Tx) error {
_, err := tx.Exec(`
CREATE TABLE software_title_team_pins (
team_id INT UNSIGNED NOT NULL,
Expand All @@ -27,6 +27,6 @@ CREATE TABLE software_title_team_pins (
return nil
}

func Down_20260617172853(tx *sql.Tx) error {
func Down_20260702013057(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
)

func TestUp_20260617172853(t *testing.T) {
func TestUp_20260702013057(t *testing.T) {
db := applyUpToPrev(t)

applyNext(t, db)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260617194413, Down_20260617194413)
MigrationClient.AddMigration(Up_20260702013058, Down_20260702013058)
}

func Up_20260617194413(tx *sql.Tx) error {
func Up_20260702013058(tx *sql.Tx) error {
_, err := tx.Exec(`
ALTER TABLE mdm_configuration_profile_variables
ADD COLUMN android_profile_uuid varchar(37) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
Expand All @@ -31,6 +31,6 @@ func Up_20260617194413(tx *sql.Tx) error {
return nil
}

func Down_20260617194413(tx *sql.Tx) error {
func Down_20260702013058(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
)

func TestUp_20260617194413(t *testing.T) {
func TestUp_20260702013058(t *testing.T) {
db := applyUpToPrev(t)

// Apply current migration.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260622124714, Down_20260622124714)
MigrationClient.AddMigration(Up_20260702013059, Down_20260702013059)
}

func Up_20260622124714(tx *sql.Tx) error {
func Up_20260702013059(tx *sql.Tx) error {
// policy_gated marks a Windows/Linux setup-experience software item whose installer has at least one team policy with an
// install-software automation pointing at it. Such an item is gated: it is skipped only if every in-scope gating policy
// passes, and installed if any fails. The set of gating policies is derived from the installer at decision time, so this is
Expand All @@ -25,6 +25,6 @@ ALTER TABLE setup_experience_status_results
return nil
}

func Down_20260622124714(tx *sql.Tx) error {
func Down_20260702013059(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260622124734, Down_20260622124734)
MigrationClient.AddMigration(Up_20260702013100, Down_20260702013100)
}

func Up_20260622124734(tx *sql.Tx) error {
func Up_20260702013100(tx *sql.Tx) error {
// First we modify the abm_tokens table to add the column for BYOD default team id, and a unique token for ADUE enrollments
_, err := tx.Exec(`ALTER TABLE abm_tokens
ADD COLUMN byod_default_team_id INT UNSIGNED NULL,
Expand Down Expand Up @@ -93,6 +93,6 @@ func Up_20260622124734(tx *sql.Tx) error {
return nil
}

func Down_20260622124734(tx *sql.Tx) error {
func Down_20260702013100(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"github.com/stretchr/testify/require"
)

func TestUp_20260622124734(t *testing.T) {
func TestUp_20260702013100(t *testing.T) {
db := applyUpToPrev(t)

// Insert two abm_tokens
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260623140135, Down_20260623140135)
MigrationClient.AddMigration(Up_20260702013101, Down_20260702013101)
}

func Up_20260623140135(tx *sql.Tx) error {
func Up_20260702013101(tx *sql.Tx) error {
// Add the new "🛟 Support" default self-service software category so it
// matches fleet.DefaultSelfServiceCategoryNames, which is used when seeding
// categories for newly created fleets.
Expand All @@ -37,6 +37,6 @@ SELECT '🛟 Support', t.id FROM teams t
return nil
}

func Down_20260623140135(tx *sql.Tx) error {
func Down_20260702013101(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"github.com/stretchr/testify/require"
)

func TestUp_20260623140135(t *testing.T) {
func TestUp_20260702013101(t *testing.T) {
db := applyUpToPrev(t)

// The global defaults seeded by earlier migrations should not yet include
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import (
)

func init() {
MigrationClient.AddMigration(Up_20260624152755, Down_20260624152755)
MigrationClient.AddMigration(Up_20260702013102, Down_20260702013102)
}

func Up_20260624152755(tx *sql.Tx) error {
func Up_20260702013102(tx *sql.Tx) error {
_, err := tx.Exec(`
ALTER TABLE mdm_configuration_profile_variables
ADD COLUMN certificate_template_id int unsigned DEFAULT NULL,
Expand Down Expand Up @@ -37,6 +37,6 @@ func Up_20260624152755(tx *sql.Tx) error {
return nil
}

func Down_20260624152755(tx *sql.Tx) error {
func Down_20260702013102(tx *sql.Tx) error {
return nil
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
)

func TestUp_20260624152755(t *testing.T) {
func TestUp_20260702013102(t *testing.T) {
db := applyUpToPrev(t)

// Apply current migration.
Expand Down
2 changes: 1 addition & 1 deletion server/datastore/mysql/schema.sql

Large diffs are not rendered by default.

Loading