I have created a Vue-cli project and it working fine on my local server. And when I 'npm run build' and deployed it to my web server I see my static-images and icon-fonts not working.
My App link : http://www.bootstrapdash.com/demo/star-admin-pro-vue/
Related
summery
I"ve tried to deploy sample Vue Nuxt SPA to AWS S3.
My Sample SPA is correctly displayed in my local Ubuntu20.04 environment with yarn start.
However SPA on S3 does not work correctly and shows error.
I want to know how to deloy correctly and show the same content as I did in my local environment.
what I've tried
Run yarn start
Confirm SPA does work in my local environment.
Run yarn generate.
Deploy /dist to S3.
Configure S3 access rigihts.
Confirm SPA does not work correctly in S3.
show some codes
here is the github repo I've tried.
https://github.com/jpskgc/vue-nuxt-spa-sample/tree/main
I built a website using npm and in it I used swiperJS installed through npm. It works fine on local development environment but when I deployed to netlify, it does not display as it should where I used the package. Thank you.
i'm new to node js, vuejs AND nuxtjs in the same times. I'm currently developping an application and my server is full. It seem that when i'm runing npm run build locally and just uploading .nuxt folder it's working well. am i doing this well ?
For deploying you application there different steps available in the official docs. Here is the available options in nuxt.
Also check this commands and deployments for nuxtjs.
Server Deployment
To deploy a SSR application we use target: 'server', where server is the default value.
npm run build
Nuxt will create a .nuxt directory with everything inside ready to be deployed on your server hosting.
Once your application is built you can use the start command to see a production version of your application.
npm run start
Static Deployment (Pre-rendered)
Nuxt gives you the ability to host your web application on any static hosting.
To deploy a static generated site make sure you have target: 'static' in your nuxt.config.js (for Nuxt >= 2.13):
// nuxt.config.js
export default {
target: 'static'
}
npm run generate
Nuxt will create a dist/ directory with everything inside ready to be deployed on a static hosting service.
I have a nuxt project which was written by someone else. I built a production build by using nuxt build --spa and tested the build in dist folder locally b using PHP's built in server and it worked fine.
But after deploying to the CPanel hosting, it's just stuck on the loading screen and does not load. I'm new to Nuxt so I'm not sure what is the problem here. The url of the staging site is here http://staging.sustainabilityinnocenter.com. Please let me know what could be the problem
I'm currently developing a web application composed of:
api: an API built with Flask in Python
app: a web app built with vue-cli (based on webpack), and minified with npm run build
I've successfully built the api with an OpenShift Python S2I (source-to-image) image: python-36-rhel7.
I'd like to be able to automatically build the static web app from source and serve it through Nginx or Apache, in a separate app from the same project.
It should:
download the app source from the git repo (context-dir=/app/)
install npm
build it with npm install and npm run build
serve the built html+js+css files
There exist a node.js S2I image but it seems to be more suited for Express.js apps.
What would be the best way to build and serve a minified static web app on OpenShift?