Skip to content

Multiple packages API changes - #48607

Merged
cdcme merged 6 commits into
feat/28108-multiple-custom-packagesfrom
feat/48397-packages-api
Jul 3, 2026
Merged

Multiple packages API changes#48607
cdcme merged 6 commits into
feat/28108-multiple-custom-packagesfrom
feat/48397-packages-api

Conversation

@cdcme

@cdcme cdcme commented Jul 1, 2026

Copy link
Copy Markdown
Member

Related issue: Resolves #48397

Summary

Adds the REST API layer for multiple custom packages per software title (backend only):

  • GET /software/titles and GET /software/titles/:id return a new packages[] array; software_package is retained as the first-added package for backwards compatibility.
  • POST /software/package adds a package to an existing title and returns the added package.
  • PATCH /software/titles/:id/package targets a specific installer_id and rejects a replacement whose hash matches a sibling package (409).
  • DELETE /software/titles/:id/available_for_install?installer_id= deletes one package; omitting installer_id deletes them all.

Builds on the data-model foundation (#48396). Install-time precedence and the host-software endpoint are out of scope (#48398).

Checklist for submitter

  • Changes file added for user-visible changes in changes/.
    See Changes files for more information.
  • Input data is properly validated, SELECT * is avoided, SQL injection is prevented (using placeholders for values in statements).
  • If paths of existing endpoints are modified without backwards compatibility, checked the frontend/CLI for any necessary changes.

Testing

  • Added/updated automated tests
  • QA'd all new/changed functionality manually

@qodo-free-for-open-source-projects

Copy link
Copy Markdown

CI Feedback 🧐

A test triggered by this PR failed. Here is an AI-generated analysis of the failure:

Action: test-go (fleetctl, mysql:8.0.44) / test

Failed stage: Run Go Tests [❌]

Failed test name: TestGetSoftwareTitles

Failure summary:

The action failed because a Go test assertion failed in cmd/fleetctl/fleetctl:
- Test
TestGetSoftwareTitles failed in cmd/fleetctl/fleetctl/get_test.go at lines 1121 and 1122.
- The test
expected a map/object without a packages field, but the actual output included an additional key
packages: nil for software titles (e.g., entries named foo and bar), causing a Not equal mismatch.
-
This single test failure caused make .run-go-tests to exit non-zero (Error 1), which then made make
test-go fail (Error 2) and the workflow ended with exit code 2.

Relevant error logs:
1:  Runner name: 'ubuntu-8core-1000966383'
2:  Runner group name: 'default larger runners'
...

1253:  �[36;1mattempt=1�[0m
1254:  �[36;1m�[0m
1255:  �[36;1mwhile [ $attempt -le $max_attempts ]; do�[0m
1256:  �[36;1m  echo "Attempt $attempt of $max_attempts"�[0m
1257:  �[36;1m�[0m
1258:  �[36;1m  # Try to connect to MySQL�[0m
1259:  �[36;1m  if wait_for_mysql "mysql_test"; then�[0m
1260:  �[36;1m    # If MySQL is ready, try to connect to MySQL replica�[0m
1261:  �[36;1m    if wait_for_mysql "mysql_replica_test"; then�[0m
1262:  �[36;1m      # Both are ready, we're done�[0m
1263:  �[36;1m      echo "All MySQL connections successful"�[0m
1264:  �[36;1m      exit 0�[0m
1265:  �[36;1m    fi�[0m
1266:  �[36;1m  fi�[0m
1267:  �[36;1m�[0m
1268:  �[36;1m  # If we get here, at least one connection failed�[0m
1269:  �[36;1m  echo "Failed to connect to MySQL on attempt $attempt"�[0m
1270:  �[36;1m�[0m
1271:  �[36;1m  if [ $attempt -lt $max_attempts ]; then�[0m
1272:  �[36;1m    echo "Restarting containers and trying again..."�[0m
1273:  �[36;1m    restart_containers�[0m
1274:  �[36;1m  else�[0m
1275:  �[36;1m    echo "Maximum attempts reached. Failing the job."�[0m
1276:  �[36;1m    exit 1�[0m
...

1430:  make .run-go-tests PKG_TO_TEST="./cmd/fleetctl/..."
1431:  make[1]: Entering directory '/home/runner/work/fleet/fleet'
1432:  Running Go tests with gotestsum:
1433:  gotestsum --format=testdox --jsonfile=/tmp/test-output.json -- -tags full,fts5,netgo -run=  -v -race=false -timeout=20m  -parallel 8 -coverprofile=coverage.txt -covermode=atomic -coverpkg=github.com/fleetdm/fleet/v4/... ././cmd/fleetctl/... 
1434:  github.com/fleetdm/fleet/v4/cmd/fleetctl:
1435:  github.com/fleetdm/fleet/v4/cmd/fleetctl/fleetctl/testing_utils:
1436:  github.com/fleetdm/fleet/v4/cmd/fleetctl/fleetctl/fleetctltest:
1437:  github.com/fleetdm/fleet/v4/cmd/fleetctl/fleetctl/goquerycmd:
1438:  github.com/fleetdm/fleet/v4/cmd/fleetctl/integrationtest:
1439:  github.com/fleetdm/fleet/v4/cmd/fleetctl/integrationtest/package:
1440:  �[32m✓�[0m Package (3.53s)
1441:  �[32m✓�[0m Package - -use-sytem-configuration can't be used on installers that aren't pkg (0.00s)
1442:  �[32m✓�[0m Package deb (1.90s)
1443:  github.com/fleetdm/fleet/v4/cmd/fleetctl/integrationtest/preview:
1444:  �[32m✓�[0m Integrations preview (53.80s)
1445:  �[32m✓�[0m Preview fails on invalid license key (0.00s)
1446:  github.com/fleetdm/fleet/v4/cmd/fleetctl/integrationtest/vuln:
...

1553:  �[32m✓�[0m Apply specs deprecated keys app config windows updates.grace period days not a number (0.42s)
1554:  �[32m✓�[0m Apply specs deprecated keys app config windows updates.grace period days out of range (0.49s)
1555:  �[32m✓�[0m Apply specs deprecated keys config with FIM values for agent options (#869 9) (0.45s)
1556:  �[32m✓�[0m Apply specs deprecated keys config with blank required org name (0.45s)
1557:  �[32m✓�[0m Apply specs deprecated keys config with blank required server url (0.49s)
1558:  �[32m✓�[0m Apply specs deprecated keys config with invalid agent options command-line flags (0.42s)
1559:  �[32m✓�[0m Apply specs deprecated keys config with invalid agent options data type in dry-run (0.41s)
1560:  �[32m✓�[0m Apply specs deprecated keys config with invalid agent options data type with force (0.39s)
1561:  �[32m✓�[0m Apply specs deprecated keys config with invalid agent options in dry-run (0.54s)
1562:  �[32m✓�[0m Apply specs deprecated keys config with invalid key type (0.49s)
1563:  �[32m✓�[0m Apply specs deprecated keys config with invalid value for agent options command-line flags (0.43s)
1564:  �[32m✓�[0m Apply specs deprecated keys config with unknown key (0.49s)
1565:  �[32m✓�[0m Apply specs deprecated keys config with valid agent options command-line flags (0.37s)
1566:  �[32m✓�[0m Apply specs deprecated keys dry-run set with unsupported spec (0.36s)
1567:  �[32m✓�[0m Apply specs deprecated keys dry-run set with various specs, appconfig warning for legacy (0.47s)
1568:  �[32m✓�[0m Apply specs deprecated keys dry-run set with various specs, no errors (0.45s)
1569:  �[32m✓�[0m Apply specs deprecated keys empty config (0.41s)
...

1572:  �[32m✓�[0m Apply specs deprecated keys invalid agent options dry-run (0.54s)
1573:  �[32m✓�[0m Apply specs deprecated keys invalid agent options field type (0.43s)
1574:  �[32m✓�[0m Apply specs deprecated keys invalid agent options field type in overrides (0.44s)
1575:  �[32m✓�[0m Apply specs deprecated keys invalid agent options for existing team (0.46s)
1576:  �[32m✓�[0m Apply specs deprecated keys invalid agent options for new team (0.51s)
1577:  �[32m✓�[0m Apply specs deprecated keys invalid agent options force (0.55s)
1578:  �[32m✓�[0m Apply specs deprecated keys invalid known key's value type for team cannot be forced (0.45s)
1579:  �[32m✓�[0m Apply specs deprecated keys invalid team agent options command-line flag (0.41s)
1580:  �[32m✓�[0m Apply specs deprecated keys invalid top-level key for team (0.43s)
1581:  �[32m✓�[0m Apply specs deprecated keys macos updates deadline set but minimum version empty (0.41s)
1582:  �[32m✓�[0m Apply specs deprecated keys macos updates minimum version set but deadline empty (0.43s)
1583:  �[32m✓�[0m Apply specs deprecated keys macos updates.deadline with incomplete date (0.63s)
1584:  �[32m✓�[0m Apply specs deprecated keys macos updates.deadline with invalid date (0.59s)
1585:  �[32m✓�[0m Apply specs deprecated keys macos updates.deadline with timestamp (0.58s)
1586:  �[32m✓�[0m Apply specs deprecated keys macos updates.minimum version with build version (0.50s)
1587:  �[32m✓�[0m Apply specs deprecated keys missing required failing policies destination url (0.36s)
1588:  �[32m✓�[0m Apply specs deprecated keys missing required host status days count (0.47s)
...

1596:  �[32m✓�[0m Apply specs deprecated keys team config macos settings.enable disk encryption true (0.46s)
1597:  �[32m✓�[0m Apply specs deprecated keys team config macos settings.enable disk encryption with invalid value type (0.63s)
1598:  �[32m✓�[0m Apply specs deprecated keys team config macos settings.enable disk encryption without a value (0.55s)
1599:  �[32m✓�[0m Apply specs deprecated keys unknown key for team can be forced (0.41s)
1600:  �[32m✓�[0m Apply specs deprecated keys valid team agent options command-line flag (0.45s)
1601:  �[32m✓�[0m Apply specs deprecated keys windows updates unset valid (0.58s)
1602:  �[32m✓�[0m Apply specs deprecated keys windows updates valid (0.55s)
1603:  �[32m✓�[0m Apply specs deprecated keys windows updates.deadline days but grace period empty (0.55s)
1604:  �[32m✓�[0m Apply specs deprecated keys windows updates.deadline days not a number (0.39s)
1605:  �[32m✓�[0m Apply specs deprecated keys windows updates.deadline days out of range (0.43s)
1606:  �[32m✓�[0m Apply specs deprecated keys windows updates.grace period days but deadline empty (0.45s)
1607:  �[32m✓�[0m Apply specs deprecated keys windows updates.grace period days not a number (0.41s)
1608:  �[32m✓�[0m Apply specs deprecated keys windows updates.grace period days out of range (0.57s)
1609:  �[32m✓�[0m Apply specs dry-run set with unsupported spec (0.39s)
1610:  �[32m✓�[0m Apply specs dry-run set with various specs, appconfig warning for legacy (0.41s)
1611:  �[32m✓�[0m Apply specs dry-run set with various specs, no errors (0.55s)
1612:  �[32m✓�[0m Apply specs empty config (0.38s)
...

1615:  �[32m✓�[0m Apply specs invalid agent options dry-run (0.44s)
1616:  �[32m✓�[0m Apply specs invalid agent options field type (0.47s)
1617:  �[32m✓�[0m Apply specs invalid agent options field type in overrides (0.51s)
1618:  �[32m✓�[0m Apply specs invalid agent options for existing team (0.41s)
1619:  �[32m✓�[0m Apply specs invalid agent options for new team (0.57s)
1620:  �[32m✓�[0m Apply specs invalid agent options force (0.36s)
1621:  �[32m✓�[0m Apply specs invalid known key's value type for team cannot be forced (0.62s)
1622:  �[32m✓�[0m Apply specs invalid team agent options command-line flag (0.37s)
1623:  �[32m✓�[0m Apply specs invalid top-level key for team (0.49s)
1624:  �[32m✓�[0m Apply specs macos updates deadline set but minimum version empty (0.37s)
1625:  �[32m✓�[0m Apply specs macos updates minimum version set but deadline empty (0.42s)
1626:  �[32m✓�[0m Apply specs macos updates.deadline with incomplete date (0.44s)
1627:  �[32m✓�[0m Apply specs macos updates.deadline with invalid date (0.45s)
1628:  �[32m✓�[0m Apply specs macos updates.deadline with timestamp (0.70s)
1629:  �[32m✓�[0m Apply specs macos updates.minimum version with build version (0.38s)
1630:  �[32m✓�[0m Apply specs missing required failing policies destination url (0.37s)
1631:  �[32m✓�[0m Apply specs missing required host status days count (0.37s)
...

1650:  �[32m✓�[0m Apply specs windows updates.grace period days not a number (0.45s)
1651:  �[32m✓�[0m Apply specs windows updates.grace period days out of range (0.37s)
1652:  �[32m✓�[0m Apply team specs (0.72s)
1653:  �[32m✓�[0m Apply user roles (0.49s)
1654:  �[32m✓�[0m Apply user roles deprecated (0.40s)
1655:  �[32m✓�[0m Apply windows updates (0.39s)
1656:  �[32m✓�[0m Apply windows updates field omitted (0.00s)
1657:  �[32m✓�[0m Apply windows updates with null values (0.01s)
1658:  �[32m✓�[0m Apply windows updates with values (0.00s)
1659:  �[32m✓�[0m Can apply intervals in nanoseconds (0.59s)
1660:  �[32m✓�[0m Can apply intervals using durations (0.48s)
1661:  �[32m✓�[0m Clean status code err (0.00s)
1662:  �[32m✓�[0m Clean status code err bare wrapped status code err (0.00s)
1663:  �[32m✓�[0m Clean status code err nil (0.00s)
1664:  �[32m✓�[0m Clean status code err outer-wrapped status code err (0.00s)
1665:  �[32m✓�[0m Clean status code err plain error untouched (0.00s)
1666:  �[32m✓�[0m Compute label changes (0.00s)
...

1722:  �[32m✓�[0m Filename functions (0.00s)
1723:  �[32m✓�[0m Filename functions outfile name builds a file name using the name provided + current time (0.00s)
1724:  �[32m✓�[0m Filename functions outfile name with ext builds a file name using the name and extension provided + current time (0.00s)
1725:  �[32m✓�[0m FleetctlUpgradePacks empty packs (0.40s)
1726:  �[32m✓�[0m FleetctlUpgradePacks no pack (0.37s)
1727:  �[32m✓�[0m FleetctlUpgradePacks non empty (0.47s)
1728:  �[32m✓�[0m FleetctlUpgradePacks not admin (0.43s)
1729:  �[32m✓�[0m Format XML (0.00s)
1730:  �[32m✓�[0m Format XML XML with attributes (0.00s)
1731:  �[32m✓�[0m Format XML basic XML (0.00s)
1732:  �[32m✓�[0m Format XML empty XML (0.00s)
1733:  �[32m✓�[0m Format XML invalid XML (0.00s)
1734:  �[32m✓�[0m Format XML nested XML (0.00s)
1735:  �[32m✓�[0m Generate MDM apple (0.72s)
1736:  �[32m✓�[0m Generate MDM apple BM (0.40s)
1737:  �[32m✓�[0m Generate MDM apple CSR API call fails (0.35s)
1738:  �[32m✓�[0m Generate MDM apple successful run (0.37s)
1739:  �[32m✓�[0m Generate MDMVPP tokens (0.00s)
1740:  �[32m✓�[0m Generate MDMVPP tokens get VPP tokens error (0.00s)
1741:  �[32m✓�[0m Generate MDMVPP tokens multiple tokens with different teams (0.00s)
...

1759:  �[32m✓�[0m Generate org settings masked google workspace api key (0.00s)
1760:  �[32m✓�[0m Generate policies (0.00s)
1761:  �[32m✓�[0m Generate policies patch policy orphaned from fleet maintained app (0.00s)
1762:  �[32m✓�[0m Generate queries (0.00s)
1763:  �[32m✓�[0m Generate software (0.00s)
1764:  �[32m✓�[0m Generate software auto update schedule (0.00s)
1765:  �[32m✓�[0m Generate software script packages (0.00s)
1766:  �[32m✓�[0m Generate team settings (0.00s)
1767:  �[32m✓�[0m Generate team settings insecure (0.00s)
1768:  �[32m✓�[0m Generated org settings no SSO (0.00s)
1769:  �[32m✓�[0m Generated org settings okta conditional access not included (0.00s)
1770:  �[32m✓�[0m Get MDM command results (0.38s)
1771:  �[32m✓�[0m Get MDM command results command flag required (0.00s)
1772:  �[32m✓�[0m Get MDM command results command not found (0.01s)
1773:  �[32m✓�[0m Get MDM command results command results empty (0.01s)
1774:  �[32m✓�[0m Get MDM command results command results error (0.01s)
1775:  �[32m✓�[0m Get MDM command results darwin command results (0.01s)
1776:  �[32m✓�[0m Get MDM command results host specific results (0.00s)
1777:  �[32m✓�[0m Get MDM command results windows command results (0.00s)
1778:  �[32m✓�[0m Get MDM commands (0.59s)
1779:  �[32m✓�[0m Get apple BM (1.85s)
1780:  �[32m✓�[0m Get apple BM free license (0.55s)
1781:  �[32m✓�[0m Get apple BM premium license, multiple tokens (0.35s)
1782:  �[32m✓�[0m Get apple BM premium license, no token (0.45s)
1783:  �[32m✓�[0m Get apple BM premium license, single token (0.51s)
1784:  �[32m✓�[0m Get apple MDM (0.36s)
1785:  �[32m✓�[0m Get carve (0.33s)
1786:  �[32m✓�[0m Get carve with error (0.41s)
1787:  �[32m✓�[0m Get carves (0.42s)
...

1801:  �[32m✓�[0m Get hosts MDM get hosts - -mdm - -mdm-pending - (0.00s)
1802:  �[32m✓�[0m Get hosts MDM get hosts - -mdm-pending - -yaml - expected list hosts yaml.yml (0.00s)
1803:  �[32m✓�[0m Get hosts get hosts - -json - -remove-deprecated-keys (0.00s)
1804:  �[32m✓�[0m Get hosts get hosts - -json - expected list hosts json.json (0.00s)
1805:  �[32m✓�[0m Get hosts get hosts - -json test host - expected host detail response json.json (0.00s)
1806:  �[32m✓�[0m Get hosts get hosts - -yaml - expected list hosts yaml.yml (0.00s)
1807:  �[32m✓�[0m Get hosts get hosts - -yaml test host - expected host detail response yaml.yml (0.00s)
1808:  �[32m✓�[0m Get label (0.36s)
1809:  �[32m✓�[0m Get label usage include and exclude allowed (0.00s)
1810:  �[32m✓�[0m Get label usage include and exclude allowed macos (0.00s)
1811:  �[32m✓�[0m Get label usage include and exclude allowed macos# 01 (0.00s)
1812:  �[32m✓�[0m Get label usage include and exclude allowed macos# 02 (0.00s)
1813:  �[32m✓�[0m Get label usage include and exclude allowed windows (0.00s)
1814:  �[32m✓�[0m Get label usage include and exclude allowed windows# 01 (0.00s)
1815:  �[32m✓�[0m Get label usage include and exclude allowed windows# 02 (0.00s)
1816:  �[32m✓�[0m Get label usage include exclude overlap error (0.00s)
1817:  �[32m✓�[0m Get label usage include exclude overlap error macos (0.00s)
1818:  �[32m✓�[0m Get label usage include exclude overlap error macos# 01 (0.00s)
1819:  �[32m✓�[0m Get label usage include exclude overlap error macos# 02 (0.00s)
1820:  �[32m✓�[0m Get label usage include exclude overlap error windows (0.00s)
1821:  �[32m✓�[0m Get label usage include exclude overlap error windows# 01 (0.00s)
1822:  �[32m✓�[0m Get label usage include exclude overlap error windows# 02 (0.00s)
1823:  �[32m✓�[0m Get label usage multiple label keys error (0.00s)
1824:  �[32m✓�[0m Get label usage multiple label keys error macos (0.00s)
1825:  �[32m✓�[0m Get label usage multiple label keys error windows (0.00s)
1826:  �[32m✓�[0m Get label usage policy scopes (0.00s)
...

1842:  �[32m✓�[0m Get queries as observer team observer (0.01s)
1843:  �[32m✓�[0m Get query (0.43s)
1844:  �[32m✓�[0m Get query labels include all (0.41s)
1845:  �[32m✓�[0m Get reports labels include all (0.33s)
1846:  �[31m✖�[0m Get software titles (0.56s)
1847:  �[32m✓�[0m Get software versions (0.39s)
1848:  �[32m✓�[0m Get teams (0.77s)
1849:  �[32m✓�[0m Get teams YAML and apply (0.44s)
1850:  �[32m✓�[0m Get teams by name (0.48s)
1851:  �[32m✓�[0m Get teams expired license (0.35s)
1852:  �[32m✓�[0m Get teams not expired license (0.43s)
1853:  �[32m✓�[0m Get teams software from source of truth (0.47s)
1854:  �[32m✓�[0m Get user roles (0.35s)
1855:  �[32m✓�[0m Git ops ABM (6.17s)
1856:  �[32m✓�[0m Git ops ABM backwards compat (0.65s)
1857:  �[32m✓�[0m Git ops ABM both keys errors (0.48s)
1858:  �[32m✓�[0m Git ops ABM deprecated config with two tokens in the db fails (0.48s)
1859:  �[32m✓�[0m Git ops ABM new key all valid (0.89s)
1860:  �[32m✓�[0m Git ops ABM new key multiple elements (0.62s)
1861:  �[32m✓�[0m Git ops ABM no team is supported (0.69s)
1862:  �[32m✓�[0m Git ops ABM non existent org name fails (0.62s)
1863:  �[32m✓�[0m Git ops ABM not provided teams defaults to no team (0.63s)
1864:  �[32m✓�[0m Git ops ABM renamed new key all valid (0.60s)
1865:  �[32m✓�[0m Git ops ABM using an undefined team errors (0.51s)
1866:  �[32m✓�[0m Git ops EULA setting (4.22s)
...

1869:  �[32m✓�[0m Git ops EULA setting not a PDF file (0.51s)
1870:  �[32m✓�[0m Git ops EULA setting relative path to working dir to pdf file (no existing EULA uploaded) (0.61s)
1871:  �[32m✓�[0m Git ops EULA setting relative path to yaml file to pdf file (no existing EULA uploaded) (0.44s)
1872:  �[32m✓�[0m Git ops EULA setting uploading the same EULA again (0.53s)
1873:  �[32m✓�[0m Git ops EULA setting valid new pdf file (different EULA already uploaded) (0.58s)
1874:  �[32m✓�[0m Git ops EULA setting valid pdf file (no existing EULA uploaded) (0.53s)
1875:  �[32m✓�[0m Git ops MDM auth settings (0.47s)
1876:  �[32m✓�[0m Git ops SMTP settings (0.48s)
1877:  �[32m✓�[0m Git ops SSO server URL (0.51s)
1878:  �[32m✓�[0m Git ops SSO settings (0.48s)
1879:  �[32m✓�[0m Git ops android certificates add (0.60s)
1880:  �[32m✓�[0m Git ops android certificates change (0.67s)
1881:  �[32m✓�[0m Git ops android certificates delete all (0.55s)
1882:  �[32m✓�[0m Git ops android certificates delete one (0.49s)
1883:  �[32m✓�[0m Git ops app store app auto update (0.39s)
1884:  �[32m✓�[0m Git ops app store app auto update invalid auto-update window triggers error and does not call update software title auto update config (0.02s)
1885:  �[32m✓�[0m Git ops app store app auto update no auto update settings and no existing schedule does not call update software title auto update config (0.02s)
1886:  �[32m✓�[0m Git ops app store app auto update update software title auto update config is applied for i OS VPP apps (0.02s)
1887:  �[32m✓�[0m Git ops app store app auto update update software title auto update config is not called when no VPP apps provided (0.02s)
1888:  �[32m✓�[0m Git ops apple OS updates (0.39s)
1889:  �[32m✓�[0m Git ops apple OS updates ios updates (0.01s)
1890:  �[32m✓�[0m Git ops apple OS updates ios updates os updated when existing OS update declaration (0.01s)
1891:  �[32m✓�[0m Git ops apple OS updates ipados updates (0.01s)
1892:  �[32m✓�[0m Git ops apple OS updates ipados updates os updated when existing OS update declaration (0.01s)
1893:  �[32m✓�[0m Git ops apple OS updates macos updates (0.01s)
1894:  �[32m✓�[0m Git ops apple OS updates macos updates os updated when existing OS update declaration (0.01s)
1895:  �[32m✓�[0m Git ops basic global and no team (0.59s)
1896:  �[32m✓�[0m Git ops basic global and no team basic global and no-team.yml (0.06s)
1897:  �[32m✓�[0m Git ops basic global and no team both global and no-team.yml define controls -- should fail (0.01s)
1898:  �[32m✓�[0m Git ops basic global and no team controls only defined in no-team.yml (0.05s)
1899:  �[32m✓�[0m Git ops basic global and no team global DOES NOT define controls -- should fail (0.02s)
1900:  �[32m✓�[0m Git ops basic global and no team global and no-team.yml DO NOT define controls -- should fail (0.01s)
1901:  �[32m✓�[0m Git ops basic global and no team global defines software -- should fail (0.01s)
1902:  �[32m✓�[0m Git ops basic global and no team no-team provided without global -- should fail (0.01s)
1903:  �[32m✓�[0m Git ops basic global and no team no-team.yml defines policy with calendar events enabled -- should fail (0.01s)
1904:  �[32m✓�[0m Git ops basic global and no team unassigned provided without global -- should fail (0.01s)
1905:  �[32m✓�[0m Git ops basic global and team (0.70s)
...

1911:  �[32m✓�[0m Git ops custom settings global macos windows custom settings valid.yml (0.42s)
1912:  �[32m✓�[0m Git ops custom settings global windows custom settings invalid label mix 2 .yml (0.56s)
1913:  �[32m✓�[0m Git ops custom settings global windows custom settings invalid label mix.yml (0.40s)
1914:  �[32m✓�[0m Git ops custom settings global windows custom settings unknown label.yml (0.48s)
1915:  �[32m✓�[0m Git ops custom settings team macos custom settings valid deprecated.yml (0.50s)
1916:  �[32m✓�[0m Git ops custom settings team macos windows custom settings invalid labels mix 2 .yml (0.56s)
1917:  �[32m✓�[0m Git ops custom settings team macos windows custom settings invalid labels mix.yml (0.48s)
1918:  �[32m✓�[0m Git ops custom settings team macos windows custom settings unknown label.yml (0.51s)
1919:  �[32m✓�[0m Git ops custom settings team macos windows custom settings valid.yml (0.49s)
1920:  �[32m✓�[0m Git ops dry run rejects invalid label platform (0.49s)
1921:  �[32m✓�[0m Git ops exception enforcement (0.56s)
1922:  �[32m✓�[0m Git ops exception enforcement free tier (0.57s)
1923:  �[32m✓�[0m Git ops exceptions preserve omitted keys (0.44s)
1924:  �[32m✓�[0m Git ops features (0.55s)
1925:  �[32m✓�[0m Git ops filename validation (0.00s)
1926:  �[32m✓�[0m Git ops fleet failing policies webhook policy IDs (0.52s)
1927:  �[32m✓�[0m Git ops fleet webhooks and tickets enabled (0.64s)
...

2084:  �[32m✓�[0m New basic file structure has expected files (0.00s)
2085:  �[32m✓�[0m New basic file structure replaces and escapes org name template var (0.00s)
2086:  �[32m✓�[0m New basic file structure strips .template. from output filenames (0.00s)
2087:  �[32m✓�[0m New dir flag (0.01s)
2088:  �[32m✓�[0m New existing dir with force (0.01s)
2089:  �[32m✓�[0m New existing dir without force (0.00s)
2090:  �[32m✓�[0m New org name YAML quoting (0.01s)
2091:  �[32m✓�[0m New org name validation (0.01s)
2092:  �[32m✓�[0m New org name validation at max length (0.01s)
2093:  �[32m✓�[0m New org name validation control characters stripped (0.01s)
2094:  �[32m✓�[0m New org name validation only control characters (0.00s)
2095:  �[32m✓�[0m New org name validation only whitespace (0.00s)
2096:  �[32m✓�[0m New org name validation too long (0.00s)
2097:  �[32m✓�[0m New output messages (0.01s)
2098:  �[32m✓�[0m New template stripping (0.01s)
2099:  �[32m✓�[0m Print auth error (0.34s)
2100:  �[32m✓�[0m Print auth error SSO disabled shows default login message (0.00s)
2101:  �[32m✓�[0m Print auth error SSO enabled shows SSO instructions (0.00s)
2102:  �[32m✓�[0m Render template (0.00s)
...

2122:  �[32m✓�[0m Run api command get scripts full path missing (0.00s)
2123:  �[32m✓�[0m Run api command get scripts team (0.00s)
2124:  �[32m✓�[0m Run api command get scripts team no cache (0.00s)
2125:  �[32m✓�[0m Run api command get typo (0.00s)
2126:  �[32m✓�[0m Run api command upload script (0.00s)
2127:  �[32m✓�[0m Run script command (0.65s)
2128:  �[32m✓�[0m Run script command disabled scripts globally (0.00s)
2129:  �[32m✓�[0m Run script command host not found (0.01s)
2130:  �[32m✓�[0m Run script command invalid file type (0.00s)
2131:  �[32m✓�[0m Run script command invalid hashbang (0.00s)
2132:  �[32m✓�[0m Run script command invalid utf 8 (0.00s)
2133:  �[32m✓�[0m Run script command missing one of script-path and script-nqme (0.00s)
2134:  �[32m✓�[0m Run script command output truncated (0.01s)
2135:  �[32m✓�[0m Run script command posix shell hashbang (0.01s)
2136:  �[32m✓�[0m Run script command script empty (0.00s)
2137:  �[32m✓�[0m Run script command script failed (0.01s)
2138:  �[32m✓�[0m Run script command script killed (0.01s)
...

2193:  �[32m✓�[0m Validate git ops group EUA global-only run degrades id p but the team's in-run file disables EU A: accepted (0.00s)
2194:  �[32m✓�[0m Validate git ops group EUA global-only run degrades id p while a stored team keeps EUA on: rejected (#4337 1) (0.00s)
2195:  �[32m✓�[0m Validate git ops group EUA no EUA enabled anywhere is accepted (0.00s)
2196:  �[32m✓�[0m Validate git ops group EUA team enables EU A, global file adds complete id P: accepted (0.00s)
2197:  �[32m✓�[0m Validate git ops group EUA team enables EU A, global file adds id p missing entity id: rejected (0.00s)
2198:  �[32m✓�[0m Validate git ops group EUA team enables EU A, global file omits id P, stored has id P: rejected (overwrite clears) (0.00s)
2199:  �[32m✓�[0m Validate git ops group EUA team enables EU A, stored has id P, no global file: accepted (0.00s)
2200:  �[32m✓�[0m Validate git ops group EUA team enables EU A, stored has no id P, no global file: rejected (0.00s)
2201:  github.com/fleetdm/fleet/v4/cmd/fleetctl/integrationtest/gitops:
2202:  �[32m✓�[0m Git ops VPP (4.80s)
2203:  �[32m✓�[0m Git ops VPP all fleets is supported (0.63s)
2204:  �[32m✓�[0m Git ops VPP all teams is supported (0.64s)
2205:  �[32m✓�[0m Git ops VPP new key all valid (0.59s)
2206:  �[32m✓�[0m Git ops VPP new key multiple elements (0.63s)
2207:  �[32m✓�[0m Git ops VPP no team is supported (0.57s)
2208:  �[32m✓�[0m Git ops VPP non existent location fails (0.55s)
2209:  �[32m✓�[0m Git ops VPP not provided teams defaults to no team (0.52s)
2210:  �[32m✓�[0m Git ops VPP using an undefined team errors (0.66s)
2211:  �[32m✓�[0m Git ops existing team VPP apps with missing team (0.52s)
...

2304:  �[32m✓�[0m Git ops team software installers team software installer with display name.yml (1.47s)
2305:  �[32m✓�[0m Integrations enterprise gitops (318.83s)
2306:  �[32m✓�[0m Integrations enterprise gitops test CA integrations (3.92s)
2307:  �[32m✓�[0m Integrations enterprise gitops test FMA labels include all (6.05s)
2308:  �[32m✓�[0m Integrations enterprise gitops test IPA software installers (10.62s)
2309:  �[32m✓�[0m Integrations enterprise gitops test JSON configuration profile escaping (1.29s)
2310:  �[32m✓�[0m Integrations enterprise gitops test add manual labels (1.54s)
2311:  �[32m✓�[0m Integrations enterprise gitops test configuration profile escaping (1.33s)
2312:  �[32m✓�[0m Integrations enterprise gitops test delete CA with certificate templates (5.99s)
2313:  �[32m✓�[0m Integrations enterprise gitops test delete mac OS setup (5.06s)
2314:  �[32m✓�[0m Integrations enterprise gitops test deleting no team YAML (2.66s)
2315:  �[32m✓�[0m Integrations enterprise gitops test disallow software setup experience (123.77s)
2316:  �[32m✓�[0m Integrations enterprise gitops test disallow software setup experience all VPP with setup experience (1.23s)
2317:  �[32m✓�[0m Integrations enterprise gitops test disallow software setup experience no team VPP (1.15s)
2318:  �[32m✓�[0m Integrations enterprise gitops test disallow software setup experience no team installers (60.53s)
2319:  �[32m✓�[0m Integrations enterprise gitops test disallow software setup experience packages fail (60.69s)
2320:  �[32m✓�[0m Integrations enterprise gitops test dry run mac OS setup script with manual agent install conflict (0.44s)
...

2350:  �[32m✓�[0m Integrations enterprise gitops test omitted top level keys global (2.49s)
2351:  �[32m✓�[0m Integrations enterprise gitops test remove custom settings from default YAML (2.58s)
2352:  �[32m✓�[0m Integrations enterprise gitops test special case teams VPP apps (3.84s)
2353:  �[32m✓�[0m Integrations enterprise gitops test special case teams VPP apps all teams (2.43s)
2354:  �[32m✓�[0m Integrations enterprise gitops test special case teams VPP apps no team (1.26s)
2355:  �[32m✓�[0m Integrations enterprise gitops test unset configuration profile labels (4.95s)
2356:  �[32m✓�[0m Integrations enterprise gitops test unset software installer labels (12.44s)
2357:  �[32m✓�[0m Integrations enterprise starter library (5.05s)
2358:  �[32m✓�[0m Integrations enterprise starter library test apply starter library premium (3.56s)
2359:  �[32m✓�[0m Integrations gitops (2.41s)
2360:  �[32m✓�[0m Integrations gitops test fleet gitops (0.54s)
2361:  �[32m✓�[0m Integrations gitops test fleet gitops DDM fleet vars requires premium (0.11s)
2362:  �[32m✓�[0m Integrations gitops test fleet gitops with fleet secrets (0.24s)
2363:  �[32m✓�[0m Integrations starter library (1.65s)
2364:  �[32m✓�[0m Integrations starter library test apply starter library free (0.19s)
2365:  === �[31mFailed�[0m
2366:  === �[31mFAIL�[0m: cmd/fleetctl/fleetctl TestGetSoftwareTitles (0.56s)
2367:  get_test.go:1121: 
2368:  Error Trace:	/home/runner/work/fleet/fleet/cmd/fleetctl/fleetctl/get_test.go:1121
2369:  Error:      	Not equal: 
2370:  expected: map[string]interface {}{"apiVersion":"1", "kind":"software_title", "spec":[]interface {}{map[string]interface {}{"app_store_app":interface {}(nil), "browser":"chrome", "display_name":"", "extension_for":"chrome", "hosts_count":2, "icon_url":interface {}(nil), "id":0, "name":"foo", "software_package":interface {}(nil), "source":"chrome_extensions", "versions":[]interface {}{map[string]interface {}{"id":0, "version":"0.0.1", "vulnerabilities":[]interface {}{"cve-123-456-001", "cve-123-456-002"}}, map[string]interface {}{"id":0, "version":"0.0.2", "vulnerabilities":[]interface {}{"cve-123-456-001"}}, map[string]interface {}{"id":0, "version":"0.0.3", "vulnerabilities":[]interface {}{"cve-123-456-003"}}}, "versions_count":3}, map[string]interface {}{"app_store_app":interface {}(nil), "browser":"", "display_name":"", "extension_for":"", "hosts_count":0, "icon_url":interface {}(nil), "id":0, "name":"bar", "software_package":interface {}(nil), "source":"deb_packages", "versions":[]interface {}{map[string]interface {}{"id":0, "version":"0.0.3", "vulnerabilities":interface {}(nil)}}, "versions_count":1}}}
...

2380:  @@ -13,2 +13,3 @@
2381:  (string) (len=4) "name": (string) (len=3) "foo",
2382:  +   (string) (len=8) "packages": (interface {}) <nil>,
2383:  (string) (len=16) "software_package": (interface {}) <nil>,
2384:  @@ -41,3 +42,3 @@
2385:  },
2386:  -  (map[string]interface {}) (len=12) {
2387:  +  (map[string]interface {}) (len=13) {
2388:  (string) (len=13) "app_store_app": (interface {}) <nil>,
2389:  @@ -50,2 +51,3 @@
2390:  (string) (len=4) "name": (string) (len=3) "bar",
2391:  +   (string) (len=8) "packages": (interface {}) <nil>,
2392:  (string) (len=16) "software_package": (interface {}) <nil>,
2393:  Test:       	TestGetSoftwareTitles
2394:  get_test.go:1122: 
2395:  Error Trace:	/home/runner/work/fleet/fleet/cmd/fleetctl/fleetctl/get_test.go:1122
2396:  Error:      	Not equal: 
2397:  expected: map[string]interface {}{"apiVersion":"1", "kind":"software_title", "spec":[]interface {}{map[string]interface {}{"app_store_app":interface {}(nil), "browser":"chrome", "display_name":"", "extension_for":"chrome", "hosts_count":2, "icon_url":interface {}(nil), "id":0, "name":"foo", "software_package":interface {}(nil), "source":"chrome_extensions", "versions":[]interface {}{map[string]interface {}{"id":0, "version":"0.0.1", "vulnerabilities":[]interface {}{"cve-123-456-001", "cve-123-456-002"}}, map[string]interface {}{"id":0, "version":"0.0.2", "vulnerabilities":[]interface {}{"cve-123-456-001"}}, map[string]interface {}{"id":0, "version":"0.0.3", "vulnerabilities":[]interface {}{"cve-123-456-003"}}}, "versions_count":3}, map[string]interface {}{"app_store_app":interface {}(nil), "browser":"", "display_name":"", "extension_for":"", "hosts_count":0, "icon_url":interface {}(nil), "id":0, "name":"bar", "software_package":interface {}(nil), "source":"deb_packages", "versions":[]interface {}{map[string]interface {}{"id":0, "version":"0.0.3", "vulnerabilities":interface {}(nil)}}, "versions_count":1}}}
...

2406:  (string) (len=13) "app_store_app": (interface {}) <nil>,
2407:  @@ -13,2 +13,3 @@
2408:  (string) (len=4) "name": (string) (len=3) "foo",
2409:  +   (string) (len=8) "packages": (interface {}) <nil>,
2410:  (string) (len=16) "software_package": (interface {}) <nil>,
2411:  @@ -41,3 +42,3 @@
2412:  },
2413:  -  (map[string]interface {}) (len=12) {
2414:  +  (map[string]interface {}) (len=13) {
2415:  (string) (len=13) "app_store_app": (interface {}) <nil>,
2416:  @@ -50,2 +51,3 @@
2417:  (string) (len=4) "name": (string) (len=3) "bar",
2418:  +   (string) (len=8) "packages": (interface {}) <nil>,
2419:  (string) (len=16) "software_package": (interface {}) <nil>,
2420:  Test:       	TestGetSoftwareTitles
2421:  DONE 921 tests, 1 failure in 650.452s
2422:  make[1]: *** [Makefile:291: .run-go-tests] Error 1
2423:  make[1]: Leaving directory '/home/runner/work/fleet/fleet'
2424:  make: *** [Makefile:406: test-go] Error 2
2425:  ##[error]Process completed with exit code 2.
2426:  Node 20 is being deprecated. This workflow is running with Node 24 by default. If you need to temporarily use Node 20, you can set the ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true environment variable. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
2427:  ##[group]Run actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a
2428:  with:
2429:  name: fleetctl-mysql8.0.44-coverage
2430:  path: ./coverage.txt
2431:  if-no-files-found: error
2432:  compression-level: 6
...

2435:  RACE_ENABLED: false
2436:  GO_TEST_TIMEOUT: 20m
2437:  DOCKER_COMMAND: docker compose -f docker-compose.yml -f docker-compose-redis-cluster.yml up -d mysql_test mysql_replica_test redis redis-cluster-1 redis-cluster-2 redis-cluster-3 redis-cluster-4 redis-cluster-5 redis-cluster-6 redis-cluster-setup s3 saml_idp mailhog mailpit smtp4dev_test
2438:  RUN_TESTS_ARG: 
2439:  CI_TEST_PKG: fleetctl
2440:  NEED_DOCKER: 1
2441:  ARTIFACT_PREFIX: fleetctl-mysql8.0.44
2442:  GOTOOLCHAIN: local
2443:  ##[endgroup]
2444:  (node:49131) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
2445:  (Use `node --trace-deprecation ...` to show where the warning was created)
2446:  With the provided path, there will be 1 file uploaded
2447:  Artifact name is valid!
2448:  Root directory input is valid!
2449:  Beginning upload of artifact content to blob storage
2450:  (node:49131) [DEP0169] DeprecationWarning: `url.parse()` behavior is not standardized and prone to errors that have security implications. Use the WHATWG URL API instead. CVEs are not issued for `url.parse()` vulnerabilities.
2451:  Uploaded bytes 2310588
2452:  Finished uploading artifact content to blob storage!
2453:  SHA256 hash of uploaded artifact zip is a657e023699ba572ba9439b9ab89112265ed6cc8be062c12a5fbcdaaf84f7e31
2454:  Finalizing artifact upload
2455:  Artifact fleetctl-mysql8.0.44-coverage.zip successfully finalized. Artifact ID 8025734912
2456:  Artifact fleetctl-mysql8.0.44-coverage has been successfully uploaded! Final size is 2310588 bytes. Artifact ID is 8025734912
2457:  Artifact download URL: https://github.com/fleetdm/fleet/actions/runs/28555725555/artifacts/8025734912
2458:  ##[group]Run c1grep() { grep "$@" || test $? = 1; }
2459:  �[36;1mc1grep() { grep "$@" || test $? = 1; }�[0m
2460:  �[36;1mc1grep -oP 'FAIL: .*$' /tmp/gotest.log > /tmp/summary.txt�[0m
2461:  �[36;1mc1grep 'test timed out after' /tmp/gotest.log >> /tmp/summary.txt�[0m
2462:  �[36;1mc1grep 'fatal error:' /tmp/gotest.log >> /tmp/summary.txt�[0m
2463:  �[36;1mc1grep -A 10 'panic: runtime error: ' /tmp/gotest.log >> /tmp/summary.txt�[0m
2464:  �[36;1mc1grep ' FAIL\t' /tmp/gotest.log >> /tmp/summary.txt�[0m
2465:  �[36;1mGO_FAIL_SUMMARY=$(head -n 5 /tmp/summary.txt | sed ':a;N;$!ba;s/\n/\\n/g')�[0m
2466:  �[36;1mecho "GO_FAIL_SUMMARY=$GO_FAIL_SUMMARY"�[0m
2467:  �[36;1mif [[ -z "$GO_FAIL_SUMMARY" ]]; then�[0m
2468:  �[36;1m  GO_FAIL_SUMMARY="unknown, please check the build URL"�[0m
2469:  �[36;1mfi�[0m
2470:  �[36;1mGO_FAIL_SUMMARY=$GO_FAIL_SUMMARY envsubst < .github/workflows/config/slack_payload_template.json > ./payload.json�[0m
2471:  shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
2472:  env:
2473:  RACE_ENABLED: false
2474:  GO_TEST_TIMEOUT: 20m
2475:  DOCKER_COMMAND: docker compose -f docker-compose.yml -f docker-compose-redis-cluster.yml up -d mysql_test mysql_replica_test redis redis-cluster-1 redis-cluster-2 redis-cluster-3 redis-cluster-4 redis-cluster-5 redis-cluster-6 redis-cluster-setup s3 saml_idp mailhog mailpit smtp4dev_test
2476:  RUN_TESTS_ARG: 
2477:  CI_TEST_PKG: fleetctl
2478:  NEED_DOCKER: 1
2479:  ARTIFACT_PREFIX: fleetctl-mysql8.0.44
2480:  GOTOOLCHAIN: local
2481:  ##[endgroup]
2482:  GO_FAIL_SUMMARY=
2483:  Node 20 is being deprecated. This workflow is running with Node 24 by default. If you need to temporarily use Node 20, you can set the ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION=true environment variable. For more information see: https://github.blog/changelog/2025-09-19-deprecation-of-node-20-on-github-actions-runners/
2484:  ##[group]Run actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a
2485:  with:
2486:  name: fleetctl-mysql8.0.44-test-log
2487:  path: /tmp/gotest.log
2488:  if-no-files-found: error
2489:  compression-level: 6
...

2492:  RACE_ENABLED: false
2493:  GO_TEST_TIMEOUT: 20m
2494:  DOCKER_COMMAND: docker compose -f docker-compose.yml -f docker-compose-redis-cluster.yml up -d mysql_test mysql_replica_test redis redis-cluster-1 redis-cluster-2 redis-cluster-3 redis-cluster-4 redis-cluster-5 redis-cluster-6 redis-cluster-setup s3 saml_idp mailhog mailpit smtp4dev_test
2495:  RUN_TESTS_ARG: 
2496:  CI_TEST_PKG: fleetctl
2497:  NEED_DOCKER: 1
2498:  ARTIFACT_PREFIX: fleetctl-mysql8.0.44
2499:  GOTOOLCHAIN: local
2500:  ##[endgroup]
2501:  (node:49155) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
2502:  (Use `node --trace-deprecation ...` to show where the warning was created)
2503:  With the provided path, there will be 1 file uploaded
2504:  Artifact name is valid!
2505:  Root directory input is valid!
2506:  Beginning upload of artifact content to blob storage
2507:  (node:49155) [DEP0169] DeprecationWarning: `url.parse()` behavior is not standardized and prone to errors that have security implications. Use the WHATWG URL API instead. CVEs are not issued for `url.parse()` vulnerabilities.
2508:  Uploaded bytes 10996
...

2524:  RACE_ENABLED: false
2525:  GO_TEST_TIMEOUT: 20m
2526:  DOCKER_COMMAND: docker compose -f docker-compose.yml -f docker-compose-redis-cluster.yml up -d mysql_test mysql_replica_test redis redis-cluster-1 redis-cluster-2 redis-cluster-3 redis-cluster-4 redis-cluster-5 redis-cluster-6 redis-cluster-setup s3 saml_idp mailhog mailpit smtp4dev_test
2527:  RUN_TESTS_ARG: 
2528:  CI_TEST_PKG: fleetctl
2529:  NEED_DOCKER: 1
2530:  ARTIFACT_PREFIX: fleetctl-mysql8.0.44
2531:  GOTOOLCHAIN: local
2532:  ##[endgroup]
2533:  (node:49168) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
2534:  (Use `node --trace-deprecation ...` to show where the warning was created)
2535:  With the provided path, there will be 1 file uploaded
2536:  Artifact name is valid!
2537:  Root directory input is valid!
2538:  Beginning upload of artifact content to blob storage
2539:  (node:49168) [DEP0169] DeprecationWarning: `url.parse()` behavior is not standardized and prone to errors that have security implications. Use the WHATWG URL API instead. CVEs are not issued for `url.parse()` vulnerabilities.
2540:  Uploaded bytes 138
...

2556:  RACE_ENABLED: false
2557:  GO_TEST_TIMEOUT: 20m
2558:  DOCKER_COMMAND: docker compose -f docker-compose.yml -f docker-compose-redis-cluster.yml up -d mysql_test mysql_replica_test redis redis-cluster-1 redis-cluster-2 redis-cluster-3 redis-cluster-4 redis-cluster-5 redis-cluster-6 redis-cluster-setup s3 saml_idp mailhog mailpit smtp4dev_test
2559:  RUN_TESTS_ARG: 
2560:  CI_TEST_PKG: fleetctl
2561:  NEED_DOCKER: 1
2562:  ARTIFACT_PREFIX: fleetctl-mysql8.0.44
2563:  GOTOOLCHAIN: local
2564:  ##[endgroup]
2565:  (node:49180) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
2566:  (Use `node --trace-deprecation ...` to show where the warning was created)
2567:  With the provided path, there will be 1 file uploaded
2568:  Artifact name is valid!
2569:  Root directory input is valid!
2570:  Beginning upload of artifact content to blob storage
2571:  (node:49180) [DEP0169] DeprecationWarning: `url.parse()` behavior is not standardized and prone to errors that have security implications. Use the WHATWG URL API instead. CVEs are not issued for `url.parse()` vulnerabilities.
2572:  Uploaded bytes 105861
...

2605:  RACE_ENABLED: false
2606:  GO_TEST_TIMEOUT: 20m
2607:  DOCKER_COMMAND: docker compose -f docker-compose.yml -f docker-compose-redis-cluster.yml up -d mysql_test mysql_replica_test redis redis-cluster-1 redis-cluster-2 redis-cluster-3 redis-cluster-4 redis-cluster-5 redis-cluster-6 redis-cluster-setup s3 saml_idp mailhog mailpit smtp4dev_test
2608:  RUN_TESTS_ARG: 
2609:  CI_TEST_PKG: fleetctl
2610:  NEED_DOCKER: 1
2611:  ARTIFACT_PREFIX: fleetctl-mysql8.0.44
2612:  GOTOOLCHAIN: local
2613:  ##[endgroup]
2614:  (node:49193) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
2615:  (Use `node --trace-deprecation ...` to show where the warning was created)
2616:  With the provided path, there will be 1 file uploaded
2617:  Artifact name is valid!
2618:  Root directory input is valid!
2619:  Beginning upload of artifact content to blob storage
2620:  (node:49193) [DEP0169] DeprecationWarning: `url.parse()` behavior is not standardized and prone to errors that have security implications. Use the WHATWG URL API instead. CVEs are not issued for `url.parse()` vulnerabilities.
2621:  Uploaded bytes 133

@codecov

codecov Bot commented Jul 2, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 76.78571% with 52 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (feat/28108-multiple-custom-packages@3ef076a). Learn more about missing BASE report.

Files with missing lines Patch % Lines
ee/server/service/software_installers.go 73.07% 8 Missing and 6 partials ⚠️
server/datastore/mysql/software_titles.go 79.31% 6 Missing and 6 partials ⚠️
server/service/software_titles.go 68.42% 7 Missing and 5 partials ⚠️
server/datastore/mysql/software.go 76.00% 3 Missing and 3 partials ⚠️
server/datastore/mysql/software_installers.go 88.37% 2 Missing and 3 partials ⚠️
server/service/software_installers.go 62.50% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@                          Coverage Diff                           @@
##             feat/28108-multiple-custom-packages   #48607   +/-   ##
======================================================================
  Coverage                                       ?   68.03%           
======================================================================
  Files                                          ?     3680           
  Lines                                          ?   234136           
  Branches                                       ?    12454           
======================================================================
  Hits                                           ?   159299           
  Misses                                         ?    60494           
  Partials                                       ?    14343           
Flag Coverage Δ
backend 69.69% <76.78%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@cdcme
cdcme force-pushed the feat/48397-packages-api branch from 103c368 to bc1e1b5 Compare July 3, 2026 15:05
@cdcme
cdcme marked this pull request as ready for review July 3, 2026 15:06
@cdcme
cdcme requested a review from a team as a code owner July 3, 2026 15:06

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude Code Review

This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.

Tip: disable this comment in your organization's Code Review settings.

@cdcme

cdcme commented Jul 3, 2026

Copy link
Copy Markdown
Member Author

@claude review once.

Comment thread ee/server/service/software_installers.go
Comment thread server/datastore/mysql/software_installers.go
Comment thread ee/server/service/software_installers.go Outdated
@cdcme

cdcme commented Jul 3, 2026

Copy link
Copy Markdown
Member Author

@claude review once

Comment thread ee/server/service/software_installers.go
Comment thread ee/server/service/software_installers.go
@cdcme

cdcme commented Jul 3, 2026

Copy link
Copy Markdown
Member Author

@claude review once

Comment thread ee/server/service/software_installers.go
Comment thread ee/server/service/software_installers.go
@cdcme
cdcme merged commit 2dd989c into feat/28108-multiple-custom-packages Jul 3, 2026
37 of 39 checks passed
@cdcme
cdcme deleted the feat/48397-packages-api branch July 3, 2026 19:34
RachelElysia added a commit that referenced this pull request Jul 8, 2026
- `installer_id` is now required on `ISoftwarePackage` — backend #48607
  (resolves #48397) landed on the feature branch and confirms the field
  name. Dropped the "TODO: make required once #48397 ships" and the
  "Optional during transition" comment.
- Reframed `packages: ISoftwarePackage[] | null` comments on both
  `ISoftwareTitle` and `ISoftwareTitleDetails` — no longer "until the
  server is on the multi-package contract," now describes the actual
  meaning (null = no custom packages, source of truth when present).
- Dropped the "TODO(48400): drop the software_package fallback once
  #48397 ships" in the details page. Fallback stays as defense against
  no-custom-packages titles (FMA / app-store branch), reframed the
  comment accordingly.
- Added `useBlockNavigation` to the custom-hooks list in
  `frontend/docs/patterns.md`.
RachelElysia added a commit that referenced this pull request Jul 8, 2026
Backend #48607 (resolves #48397) landed on the feature branch; tests
now hit the real API contract. The `multi-package-handlers.ts` file
had no consumers beyond its own tests (self-testing MSW stubs), so
both files are deleted.
georgekarrv added a commit that referenced this pull request Jul 15, 2026
**Related issue:** Resolves #28108

Adds support for uploading multiple custom packages (up to 10) for the
same software title on a team — so IT admins can deploy different
versions or architectures (for example, Arm vs. Intel builds or staged
rollouts) to label-scoped hosts instead of splitting them across teams.
The software title keeps a single first-added `software_package` for
backwards compatibility, and first-added-wins resolves overlaps
consistently across self-service, manual install, policy automation, and
setup experience.

Feature branch combining the sub-PRs: migration (#48596), packages[] API
and add/edit/delete-package endpoints (#48607), install-time precedence
and setup experience (#48708), GitOps (#48710), Library and
Add/Edit/Delete modals (#48520), secondary UI — policy automation, setup
experience, and install-details hash (#49079), and the host
install-result `hash_sha256` field (#49085).

# Checklist for submitter

- [x] Changes file added for user-visible changes in `changes/`,
`orbit/changes/` or `ee/fleetd-chrome/changes`.
- [x] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements), JS
inline code is prevented especially for url redirects, and untrusted
data interpolated into shell scripts/commands is validated against shell
metacharacters.

## Testing

- [x] Added/updated automated tests
- [x] QA'd all new/changed functionality manually

## Database migrations

- [x] Checked schema for all modified table for columns that will
auto-update timestamps during migration.
- [x] Confirmed that updating the timestamps is acceptable, and will not
cause unwanted side effects.
- [x] Ensured the correct collation is explicitly set for character
columns (`COLLATE utf8mb4_unicode_ci`).


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Support up to 10 custom packages per software title, with
package-scoped deploy/install settings and package-specific edit/delete.
  * Policy automation can pin “Install software” to a specific package.
* GitOps generation now outputs repeatable multi-package YAML per title.
* Software install details now display the package SHA-256 hash (when
available) with a copy-to-clipboard action.
* **Bug Fixes**
* Improved deterministic “first-added” precedence for installs,
listings, setup experience, and policy dispatch when multiple packages
match.
* Fixed installer targeting and per-package metadata persistence
(including installer-specific activity details).
* **Accessibility/UX**
  * Added optional `aria-label` support for dropdowns.
  * Info banners can now render a leading icon with configurable color.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
georgekarrv added a commit that referenced this pull request Jul 22, 2026
…TeamTitleAndInstallerID (#49760)

**Related issue:** N/A — RC branch build/CI fix

## What & why

The Docker publish for **4.89.2** on `rc-patch-fleet-v4.89.2` was
failing to compile, and the `mysql` test suite + Go linters were red —
all from the same root cause: a **broken cherry-pick**.

**1. Missing datastore method (broke Docker publish + all binary
builds):**

```
server/datastore/mysql/software_installers.go:748:30:
  ds.GetSoftwareInstallerMetadataByTeamTitleAndInstallerID undefined
```

The FMA patch-policy fix (#49519, commit `9603e84cc4`) was cherry-picked
in, bringing a *caller* of
`GetSoftwareInstallerMetadataByTeamTitleAndInstallerID`, but the method
itself was introduced on `main` by the large "Multiple packages API
changes" feature PR (#48607), which is not part of this release.

**2. Stale test assertion (broke `mysql` test suite +
`lint`/`lint-incremental` typecheck):**

```
server/datastore/mysql/software_installers_test.go:6362:11:
  assignment mismatch: 2 variables but ds.RecordPolicyQueryExecutions returns 1 value
```

The same cherry-pick brought a test that calls
`RecordPolicyQueryExecutions` expecting `([]uint, error)` (its signature
on `main`), but on this RC branch it returns just `error`. A
non-compiling test package fails both the mysql suite and the linter's
typecheck pass.

## Fix

- Added `GetSoftwareInstallerMetadataByTeamTitleAndInstallerID` as a
self-contained, minimal addition (interface + datastore impl +
regenerated mock), refactoring
`GetSoftwareInstallerMetadataByTeamAndTitleID` to share a private helper
that takes an optional installer ID. The `nil` path preserves existing
behavior exactly; a non-nil ID selects that specific package by `si.id`.
- Fixed the stale test call to match the RC branch's single-return
signature (the discarded first return value is simply dropped).

No production behavior change for existing callers.

# Checklist for submitter

- [x] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements), JS
inline code is prevented especially for url redirects, and untrusted
data interpolated into shell scripts/commands is validated against shell
metacharacters.

## Testing

- [x] Added/updated automated tests
- [x] QA'd all new/changed functionality manually

For unreleased bug fixes in a release candidate, one of:

- [x] Confirmed that the fix is not expected to adversely impact load
test results

---------

Co-authored-by: test <test@test.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Multiple packages: packages[] API and add/edit/delete-package endpoints

2 participants