fix: rename all packages from @mosaic/* to @mosaicstack/*
- Updated all package.json name fields and dependency references - Updated all TypeScript/JavaScript imports - Updated .woodpecker/publish.yml filters and registry paths - Updated tools/install.sh scope default - Updated .npmrc registry paths (worktree + host) - Enhanced update-checker.ts with checkForAllUpdates() multi-package support - Updated CLI update command to show table of all packages - Added KNOWN_PACKAGES, formatAllPackagesTable, getInstallAllCommand - Marked checkForUpdate() with @deprecated JSDoc Closes #391
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "@mosaic/auth",
|
||||
"name": "@mosaicstack/auth",
|
||||
"version": "0.0.2",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -28,7 +28,7 @@
|
||||
"vitest": "^2.0.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@mosaic/db": "workspace:^",
|
||||
"@mosaicstack/db": "workspace:^",
|
||||
"better-auth": "^1.5.5"
|
||||
},
|
||||
"publishConfig": {
|
||||
|
||||
@@ -50,7 +50,7 @@ describe('buildOAuthProviders', () => {
|
||||
process.env['WORKOS_CLIENT_ID'] = 'client_test123';
|
||||
|
||||
expect(() => buildOAuthProviders()).toThrow(
|
||||
'@mosaic/auth: WorkOS SSO requires WORKOS_ISSUER, WORKOS_CLIENT_ID, WORKOS_CLIENT_SECRET.',
|
||||
'@mosaicstack/auth: WorkOS SSO requires WORKOS_ISSUER, WORKOS_CLIENT_ID, WORKOS_CLIENT_SECRET.',
|
||||
);
|
||||
});
|
||||
|
||||
@@ -97,7 +97,7 @@ describe('buildOAuthProviders', () => {
|
||||
process.env['KEYCLOAK_CLIENT_SECRET'] = 'secret123';
|
||||
|
||||
expect(() => buildOAuthProviders()).toThrow(
|
||||
'@mosaic/auth: Keycloak SSO requires KEYCLOAK_CLIENT_ID, KEYCLOAK_CLIENT_SECRET, KEYCLOAK_ISSUER.',
|
||||
'@mosaicstack/auth: Keycloak SSO requires KEYCLOAK_CLIENT_ID, KEYCLOAK_CLIENT_SECRET, KEYCLOAK_ISSUER.',
|
||||
);
|
||||
});
|
||||
|
||||
@@ -129,7 +129,7 @@ describe('buildOAuthProviders', () => {
|
||||
process.env['AUTHENTIK_CLIENT_ID'] = 'authentik-client';
|
||||
|
||||
expect(() => buildOAuthProviders()).toThrow(
|
||||
'@mosaic/auth: Authentik SSO requires AUTHENTIK_ISSUER, AUTHENTIK_CLIENT_ID, AUTHENTIK_CLIENT_SECRET.',
|
||||
'@mosaicstack/auth: Authentik SSO requires AUTHENTIK_ISSUER, AUTHENTIK_CLIENT_ID, AUTHENTIK_CLIENT_SECRET.',
|
||||
);
|
||||
});
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ import { betterAuth } from 'better-auth';
|
||||
import { drizzleAdapter } from 'better-auth/adapters/drizzle';
|
||||
import { admin } from 'better-auth/plugins';
|
||||
import { genericOAuth, type GenericOAuthConfig } from 'better-auth/plugins/generic-oauth';
|
||||
import type { Db } from '@mosaic/db';
|
||||
import type { Db } from '@mosaicstack/db';
|
||||
import { buildGenericOidcProviderConfigs } from './sso.js';
|
||||
|
||||
export interface AuthConfig {
|
||||
|
||||
@@ -66,7 +66,7 @@ function buildAuthentikConfig(env: EnvMap): GenericOidcProviderConfig | null {
|
||||
const presentCount = fields.filter(Boolean).length;
|
||||
if (presentCount > 0 && presentCount < fields.length) {
|
||||
throw new Error(
|
||||
'@mosaic/auth: Authentik SSO requires AUTHENTIK_ISSUER, AUTHENTIK_CLIENT_ID, AUTHENTIK_CLIENT_SECRET.',
|
||||
'@mosaicstack/auth: Authentik SSO requires AUTHENTIK_ISSUER, AUTHENTIK_CLIENT_ID, AUTHENTIK_CLIENT_SECRET.',
|
||||
);
|
||||
}
|
||||
if (!issuer || !clientId || !clientSecret) {
|
||||
@@ -97,7 +97,7 @@ function buildWorkosConfig(env: EnvMap): GenericOidcProviderConfig | null {
|
||||
const presentCount = fields.filter(Boolean).length;
|
||||
if (presentCount > 0 && presentCount < fields.length) {
|
||||
throw new Error(
|
||||
'@mosaic/auth: WorkOS SSO requires WORKOS_ISSUER, WORKOS_CLIENT_ID, WORKOS_CLIENT_SECRET.',
|
||||
'@mosaicstack/auth: WorkOS SSO requires WORKOS_ISSUER, WORKOS_CLIENT_ID, WORKOS_CLIENT_SECRET.',
|
||||
);
|
||||
}
|
||||
if (!issuer || !clientId || !clientSecret) {
|
||||
@@ -135,7 +135,7 @@ function buildKeycloakConfig(env: EnvMap): GenericOidcProviderConfig | null {
|
||||
const anySet = !!(issuer || clientId || clientSecret);
|
||||
if (anySet && (!issuer || !clientId || !clientSecret)) {
|
||||
throw new Error(
|
||||
'@mosaic/auth: Keycloak SSO requires KEYCLOAK_CLIENT_ID, KEYCLOAK_CLIENT_SECRET, KEYCLOAK_ISSUER.',
|
||||
'@mosaicstack/auth: Keycloak SSO requires KEYCLOAK_CLIENT_ID, KEYCLOAK_CLIENT_SECRET, KEYCLOAK_ISSUER.',
|
||||
);
|
||||
}
|
||||
if (!issuer || !clientId || !clientSecret) {
|
||||
|
||||
Reference in New Issue
Block a user