Research
Security News
Quasar RAT Disguised as an npm Package for Detecting Vulnerabilities in Ethereum Smart Contracts
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
ember-cli-deploy-adonis
Advanced tools
Build and publish your ember frontend app into an adonis backend app.
This plugin is an ember-cli-deploy plugin that copies your application assets and index.html to your directory of choice.
Intended to be used with AdonisJS but can be used where copying your project files to a directory is required.
pnpm add -D ember-cli-deploy-adonis
Add an adonis section to your deploy config ENV:
// config/deploy.js
const ENV = {
build: {},
adonis: {
destDir: "../server/public/web/",
indexFileLocation: "../server/resources/views/ember-web-index.edge",
filePattern: [
"**/*.{js,css,png,gif,ico,jpg,webp,mp3,map,xml,txt,svg,swf,eot,ttf,woff,woff2,otf,wasm,json}",
"!**/ember-electron/*",
],
},
};
In ember-cli-build.js
update your fingerprinting options to include the prepend
option:
function isProduction() {
return EmberApp.env() === "production";
}
function getPublicAssetsUrl() {
if (isProduction()) {
if (process.env.ADONIS_BUILD) return "/web/";
return "https://cdn.ekto.tv/ekto-web/";
}
return "/";
}
const app = new EmberApp(defaults, {
fingerprint: {
prepend: getPublicAssetsUrl(),
},
// ... other options
});
If you're using embroider set your publicAssetsUrl
// ... other options
packagerOptions: {
publicAssetURL: getPublicAssetsUrl(),
// ... other options
},
// ... other options
Add a wildcard route to your adonis application
Route.get("*", "EmberWebController.index");
Create a controller to serve your index file
// app/Controllers/Http/EmberWebController.js
import type { HttpContextContract } from '@ioc:Adonis/Core/HttpContext';
export default class EmberWebController {
public async index({ view }: HttpContextContract) {
return view.render('ember-web-index');
}
}
See the Contributing guide for details.
This project is licensed under the MIT License.
FAQs
Build and publish your ember frontend app into an adonis backend app.
We found that ember-cli-deploy-adonis demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover a malicious npm package posing as a tool for detecting vulnerabilities in Etherium smart contracts.
Security News
Research
A supply chain attack on Rspack's npm packages injected cryptomining malware, potentially impacting thousands of developers.
Research
Security News
Socket researchers discovered a malware campaign on npm delivering the Skuld infostealer via typosquatted packages, exposing sensitive data.