-- Migration 077 — Barracuda Networks, Peplink, Westermo
--
-- All URLs verified HTTP 200 (2026-04-21).
--
-- Barracuda Networks:
--   CloudGen Firewall F900: cdn.blueally.com (barraguard partner CDN, 69KB PNG).
--     barracuda.com/support and campus.barracuda.com return 403 for scraping;
--     barraguard.com (authorized partner) hosts the image on the blueally CDN.
--
-- Peplink:
--   SD Switch 24-Port: cdn.blueally.com (peplinkworks partner CDN, 35KB JPEG).
--     peplink.com product gallery images require JS rendering;
--     peplinkworks.com (authorized reseller) exposes static CDN images.
--     Note: model is the "Rugged" 24-port SD Switch (IP67-rated);
--     confirmed matching the SD Switch 24-Port entry in the DB.
--
-- Westermo:
--   Lynx 5612-F4G-T8G: westermo.eworldme.com Shopify CDN (14KB JPEG, 200 OK).
--     media.westermo.com returns text/html (not an image) for direct CDN paths;
--     westermo.eworldme.com is an authorized Westermo reseller with stable
--     versioned Shopify CDN URLs.

-- ── Barracuda Networks ────────────────────────────────────────────────────────

-- CloudGen Firewall F900 — 8-port 10G rackmount enterprise firewall
UPDATE switches
SET image_url        = 'https://cdn.blueally.com/barraguard/images/ng-firewall/ngfirewall-f900.png',
    product_page_url = COALESCE(product_page_url, 'https://www.barracuda.com/products/cloudgen-firewall/models'),
    assets_scraped_at = NOW()
WHERE model = 'CloudGen Firewall F900'
  AND vendor_id = (SELECT id FROM vendors WHERE slug = 'barracuda-networks');

-- ── Peplink ───────────────────────────────────────────────────────────────────

-- SD Switch 24-Port — 24×1G RJ-45 rugged managed SD-WAN-ready switch
UPDATE switches
SET image_url        = 'https://cdn.blueally.com/peplinkworks/images/sd-switch-rugged/24-port-switch-rugged-front.jpg',
    product_page_url = COALESCE(product_page_url, 'https://www.peplink.com/products/sd-switch/'),
    assets_scraped_at = NOW()
WHERE model = 'SD Switch 24-Port'
  AND vendor_id = (SELECT id FROM vendors WHERE slug = 'peplink');

-- ── Westermo ──────────────────────────────────────────────────────────────────

-- Lynx 5612-F4G-T8G — 4×100M SFP + 8×1G RJ-45 DIN-rail managed switch
-- Image from westermo.eworldme.com Shopify reseller CDN (official photo)
UPDATE switches
SET image_url        = 'https://westermo.eworldme.com/cdn/shop/files/Westermo-Lynx-5612-F4G-T8G-LV-Easy-World-Automation-Front.jpg?v=1726655230',
    product_page_url = COALESCE(product_page_url, 'https://www.westermo.com/products/switches/lynx/lynx-5612-f4g-t8g-lv'),
    assets_scraped_at = NOW()
WHERE model = 'Lynx 5612-F4G-T8G'
  AND vendor_id = (SELECT id FROM vendors WHERE slug = 'westermo');
