Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@amplication/plugin-db-mongo

Package Overview
Dependencies
Maintainers
7
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@amplication/plugin-db-mongo - npm Package Compare versions

Comparing version 1.2.4 to 1.2.5

.amplicationrc.json

5

dist/index.d.ts

@@ -1,2 +0,2 @@

import { DsgContext, AmplicationPlugin, CreateServerDockerComposeDBParams, CreateServerDockerComposeParams, CreateServerDotEnvParams, CreatePrismaSchemaParams, Events, Entity, CreateServerPackageJsonParams, CreateServerParams, LoadStaticFilesParams, Module } from "@amplication/code-gen-types";
import { DsgContext, AmplicationPlugin, CreateServerDockerComposeDBParams, CreateServerDockerComposeParams, CreateServerDotEnvParams, CreatePrismaSchemaParams, Events, Entity, CreateServerPackageJsonParams, CreateServerParams } from "@amplication/code-gen-types";
declare class MongoPlugin implements AmplicationPlugin {

@@ -9,4 +9,3 @@ register(): Events;

beforeCreateServerDockerComposeDB(context: DsgContext, eventParams: CreateServerDockerComposeDBParams): CreateServerDockerComposeDBParams;
afterCreateServerDockerComposeDB(context: DsgContext): Promise<Module[]>;
afterCreateServerStaticFiles(context: DsgContext, eventParams: LoadStaticFilesParams, modules: Module[]): Promise<Module[]>;
afterCreateServerDockerComposeDB(context: DsgContext): Promise<import("@amplication/code-gen-types").Module[]>;
beforeCreatePrismaSchema(context: DsgContext, eventParams: CreatePrismaSchemaParams): {

@@ -13,0 +12,0 @@ dataSource: import("prisma-schema-dsl-types").DataSource;

10

package.json
{
"name": "@amplication/plugin-db-mongo",
"version": "1.2.4",
"version": "1.2.5",
"description": "Use a Mongo database in a service generated by Amplication",

@@ -14,3 +14,3 @@ "main": "dist/index.js",

"devDependencies": {
"@amplication/code-gen-types": "^1.1.25",
"@amplication/code-gen-types": "^1.1.21",
"@babel/parser": "^7.18.11",

@@ -28,4 +28,4 @@ "@babel/types": "^7.18.10",

"prettier": "^2.7.1",
"prisma-schema-dsl": "^2.0.3",
"prisma-schema-dsl-types": "^1.0.5",
"prisma-schema-dsl": "^2.0.7",
"prisma-schema-dsl-types": "^1.0.8",
"ts-loader": "^9.4.2",

@@ -36,2 +36,2 @@ "typescript": "4.6.2",

}
}
}

@@ -5,7 +5,3 @@ import {

} from "@amplication/code-gen-types";
import {
DataSource,
DataSourceProvider,
DataSourceURLEnv,
} from "prisma-schema-dsl-types";
import { DataSource, DataSourceProvider } from "prisma-schema-dsl-types";

@@ -17,3 +13,4 @@ export const envVariables: VariableDictionary = [

{
DB_URL: "mongodb://${dbUser}:${dbPassword}@${dbHost}:27017/dbName?authSource=admin",
DB_URL:
"mongodb://${dbUser}:${dbPassword}@${dbHost}:27017/dbName?authSource=admin",
},

@@ -64,4 +61,5 @@ ];

provider: DataSourceProvider.MongoDB,
url: new DataSourceURLEnv("DB_URL"),
url: {
name: "DB_URL",
},
};

@@ -23,4 +23,2 @@ import { resolve } from "path";

types,
LoadStaticFilesParams,
Module,
} from "@amplication/code-gen-types";

@@ -31,3 +29,2 @@ import { ScalarType, ReferentialActions } from "prisma-schema-dsl-types";

import { pascalCase } from "pascal-case";
import { merge } from "lodash";

@@ -56,5 +53,2 @@ class MongoPlugin implements AmplicationPlugin {

},
LoadStaticFiles: {
after: this.afterCreateServerStaticFiles,
},
};

@@ -139,20 +133,2 @@ }

async afterCreateServerStaticFiles(
context: DsgContext,
eventParams: LoadStaticFilesParams,
modules: Module[]
) {
const staticPath = resolve(__dirname, "./static/health");
const staticsFiles = await context.utils.importStaticModules(
staticPath,
`${context.serverDirectories.srcDirectory}/health/base`
);
const updateModules = modules.filter(
(x) => !x.path.includes("health.service.base")
);
return [...staticsFiles, ...updateModules];
}
beforeCreatePrismaSchema(

@@ -159,0 +135,0 @@ context: DsgContext,

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc