chore(types,framework): pick ssl types from tls lib (#11381)
* chore(types,framework): pick ssl types from tls lib * chore: call from node:tls directly
This commit is contained in:
@@ -4,6 +4,7 @@ import {
|
||||
} from "@medusajs/types"
|
||||
|
||||
import type { RedisOptions } from "ioredis"
|
||||
import { ConnectionOptions } from "node:tls"
|
||||
// @ts-expect-error
|
||||
import type { InlineConfig } from "vite"
|
||||
|
||||
@@ -89,12 +90,12 @@ export type AdminOptions = {
|
||||
/**
|
||||
* Configure the Vite configuration for the admin dashboard. This function receives the default Vite configuration
|
||||
* and returns the modified configuration. The default value is `undefined`.
|
||||
*
|
||||
*
|
||||
* Learn about configurations you can pass to Vite in [Vite's documentation](https://vite.dev/config/).
|
||||
*
|
||||
* @example
|
||||
* For example, if you're using a third-party library that isn't ESM-compatible, add it to Vite's `optimizeDeps` configuration:
|
||||
*
|
||||
*
|
||||
* ```ts title="medusa-config.ts"
|
||||
* module.exports = defineConfig({
|
||||
* admin: {
|
||||
@@ -304,12 +305,7 @@ export type ProjectConfigOptions = {
|
||||
/**
|
||||
* Configure support for TLS/SSL connection
|
||||
*/
|
||||
ssl?: {
|
||||
/**
|
||||
* Whether to fail connection if the server certificate is verified against the list of supplied CAs and the hostname and no match is found.
|
||||
*/
|
||||
rejectUnauthorized?: false
|
||||
}
|
||||
ssl?: boolean | ConnectionOptions
|
||||
}
|
||||
}
|
||||
|
||||
@@ -851,7 +847,7 @@ export type ConfigModule = {
|
||||
* - An object having the following properties:
|
||||
* - `resolve`: The name of the plugin's package as specified in the plugin's `package.json` file.
|
||||
* - `options`: An object that includes options to be passed to the modules within the plugin. Learn more in [this documentation](https://docs.medusajs.com/learn/fundamentals/modules/options).
|
||||
*
|
||||
*
|
||||
* Learn how to create a plugin in [this documentation](https://docs.medusajs.com/learn/fundamentals/plugins/create).
|
||||
*
|
||||
* @example
|
||||
@@ -874,9 +870,9 @@ export type ConfigModule = {
|
||||
*/
|
||||
plugins: (
|
||||
| {
|
||||
/**
|
||||
* The name of the plugin's package as specified in the plugin's `package.json` file.
|
||||
*/
|
||||
/**
|
||||
* The name of the plugin's package as specified in the plugin's `package.json` file.
|
||||
*/
|
||||
resolve: string
|
||||
/**
|
||||
* An object that includes options to be passed to the modules within the plugin.
|
||||
|
||||
@@ -4,6 +4,7 @@ import {
|
||||
} from "../modules-sdk"
|
||||
|
||||
import type { RedisOptions } from "ioredis"
|
||||
import { ConnectionOptions } from "node:tls"
|
||||
// @ts-ignore
|
||||
import type { InlineConfig } from "vite"
|
||||
|
||||
@@ -280,12 +281,7 @@ export type ProjectConfigOptions = {
|
||||
/**
|
||||
* Configure support for TLS/SSL connection
|
||||
*/
|
||||
ssl?: {
|
||||
/**
|
||||
* Whether to fail connection if the server certificate is verified against the list of supplied CAs and the hostname and no match is found.
|
||||
*/
|
||||
rejectUnauthorized?: false
|
||||
}
|
||||
ssl?: boolean | ConnectionOptions
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user