Skip to content

Instantly share code, notes, and snippets.

@acacha
Created December 4, 2019 19:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save acacha/54b1f1540e858cfd6075f4593931ea07 to your computer and use it in GitHub Desktop.
Save acacha/54b1f1540e858cfd6075f4593931ea07 to your computer and use it in GitHub Desktop.
PROJECTE MOIXONET NUXT A NOW

Troubleshooting

No troba dotenv al instal·lar a now

Repasseu el fitxer packaeg.json mireu el del professor:

En el meu cas @nuxtjs/dotenv estava a devDependencies i cal posar a dependencies. Esborrar node_modules i tornar a peer npm install

Variables env explotació

Tenim dos variables:

En explotació cal que apuntin a backend explotació vostre, per aixó cal canviar el fitxer now.json:

https://github.com/acacha/moixonet-nuxt-frontend/blob/production/now.json

Afegint:

,
  "build": {
    "env": {
      "VUE_APP_LARAVEL_PASSPORT_ENDPOINT": "https://moixonet.acacha.scool.cat",
      "VUE_APP_LARAVEL_ENDPOINT": "https://moixonet.acacha.scool.cat"
    }
  }

Un cop afegir només cal tornar a fer deployments:

now
nom --prod

Actualitzeu la branca production (fent merge de master)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment