From 9f6b3215cc5687a278205778b82b6606ebf503d7 Mon Sep 17 00:00:00 2001 From: Light13008 Date: Sat, 5 Oct 2024 15:28:54 +0530 Subject: [PATCH] removed the cacheubg after installing packages. --- apps/generator/Dockerfile | 8 ++++--- .../__transpiled/test-file.md.js | 4 ++-- package-lock.json | 22 +++++++++++++++++-- 3 files changed, 27 insertions(+), 7 deletions(-) diff --git a/apps/generator/Dockerfile b/apps/generator/Dockerfile index 426ece721..7962d7a51 100644 --- a/apps/generator/Dockerfile +++ b/apps/generator/Dockerfile @@ -11,9 +11,11 @@ ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD true # Since 0.30.0 release Git is supported and required as a dependency # Since 0.14.0 release of html-template chromium is needed for pdf generation. # More custom packages for specific template should not be added to this dockerfile. Instead, we should come up with some extensibility solution. -RUN apk --update add git chromium && \ - rm -rf /var/lib/apt/lists/* && \ - rm /var/cache/apk/* +#is the following code correct for removing the cache after installing packages or stor it in cache mount? +RUN apk --update add --no-cache git chromium && \ + npm install -g @asyncapi/generator@$ASYNCAPI_GENERATOR_VERSION && \ + npm cache clean --force + # Installing latest released npm package RUN npm install -g @asyncapi/generator@$ASYNCAPI_GENERATOR_VERSION diff --git a/apps/generator/test/test-templates/react-template/__transpiled/test-file.md.js b/apps/generator/test/test-templates/react-template/__transpiled/test-file.md.js index 93c5b0245..adebd8d41 100644 --- a/apps/generator/test/test-templates/react-template/__transpiled/test-file.md.js +++ b/apps/generator/test/test-templates/react-template/__transpiled/test-file.md.js @@ -1,8 +1,8 @@ 'use strict'; require('source-map-support/register'); -const generatorReactSdk = require('@asyncapi/generator-react-sdk'); -const jsxRuntime = require('react/cjs/react-jsx-runtime.production.min'); +var generatorReactSdk = require('@asyncapi/generator-react-sdk'); +var jsxRuntime = require('/media/sarvesh-patil/all-Set-Up/GSOC/generator/apps/generator/node_modules/react/cjs/react-jsx-runtime.production.min.js'); function testFile_md ({ asyncapi, diff --git a/package-lock.json b/package-lock.json index 434b3c16e..bc934a2da 100644 --- a/package-lock.json +++ b/package-lock.json @@ -7134,6 +7134,20 @@ "version": "1.0.0", "license": "ISC" }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, "node_modules/function-bind": { "version": "1.1.2", "license": "MIT", @@ -10733,7 +10747,9 @@ } }, "node_modules/micromatch": { - "version": "4.0.7", + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", "dev": true, "license": "MIT", "dependencies": { @@ -12769,7 +12785,9 @@ } }, "node_modules/rollup": { - "version": "2.79.1", + "version": "2.79.2", + "resolved": "https://registry.npmjs.org/rollup/-/rollup-2.79.2.tgz", + "integrity": "sha512-fS6iqSPZDs3dr/y7Od6y5nha8dW1YnbgtsyotCVvoFGKbERG++CVRFv1meyGDE1SNItQA8BrnCw7ScdAhRJ3XQ==", "license": "MIT", "bin": { "rollup": "dist/bin/rollup"