No More Posting New Topics!

If you have a question or an issue, please start a thread in our Github Discussions Forum.
This forum is closed for new threads/ topics.

Navigation

    Quasar Framework

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Quasar + Vagrant

    CLI
    7
    11
    638
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      CodeKiddo last edited by

      Hi, I was able to run quasar app in my vagrant but the hot reload is not working? Can you please advise?

      Vagrant:
      admin.sample.local

      When I run “quasar dev”, I use the link “admin.sample.local:3000” in my browser and it loads fine. However, when I modified some vue files, the hot reload is not working, I need to re-run again the “quarsar dev” for it to take effect in the browser.

      Thanks 🙂

      1 Reply Last reply Reply Quote 0
      • M
        Max last edited by Max

        have you searched online for a solution?
        -> http://tommylee.co/tutorials/fixing-hot-reload-vagrant.html

        you might also have to customize the webpack config to specify the new host, but dont know for sure

        1 Reply Last reply Reply Quote 0
        • s.molinari
          s.molinari last edited by

          Change to Docker. It’s so much better.

          Scott

          1 Reply Last reply Reply Quote 0
          • C
            CodeKiddo last edited by

            @Max it does not fix the issue. I am also seeing this in the console log:

            [HMR] Waiting for update signal from WDS…

            1 Reply Last reply Reply Quote 0
            • J
              josephd last edited by

              In the quasar.conf.js file, you need to add watchOptions in devServer to make hotreload work properly:

                  // Full list of options: https://quasar.dev/quasar-cli/quasar-conf-js#Property%3A-devServer
                  devServer: {
                    https: false,
                    port: 8080,
                    open: false, // we cannot open browser window on headless vagrant
                    watchOptions: {
                      aggregateTimeout: 100,
                      poll: 1000
                    }
                  },
              

              You can play around with aggregateTimeout and poll but if you set them too low then the browser will just constantly refresh.

              dobbel 1 Reply Last reply Reply Quote 2
              • dobbel
                dobbel @josephd last edited by

                @josephd where did you find that info? There’s nothing in the Quasar docs about that.

                qyloxe 1 Reply Last reply Reply Quote 0
                • qyloxe
                  qyloxe @dobbel last edited by

                  @dobbel those are webpack docs:

                  https://webpack.js.org/configuration/dev-server/

                  1 Reply Last reply Reply Quote 1
                  • J
                    josephd last edited by

                    @dobbel Long story actually… I actually got this solution from a Slack group when trying to get Laravel Mix (which is a webpack wrapper) working on vagrant. So I knew which setting were needed and just used good old trial-and-error pasting them all over the place in quasar.conf.js until it worked 🙂

                    @qyloxe is right though, it’s actually detailed in the webpack docs and I guess it’s pretty much the same solution for a variety of different systems that use webpack in one way or another.

                    1 Reply Last reply Reply Quote 0
                    • PeterQF
                      PeterQF last edited by

                      i agree with @s-molinari . I use Lando to develop in Docker. I can really recommend it.

                      1 Reply Last reply Reply Quote 0
                      • s.molinari
                        s.molinari last edited by s.molinari

                        And now that WSL2 is out, there are no reasons left to stick with Vagrant on Windows 10. 🙂

                        Scott

                        qyloxe 1 Reply Last reply Reply Quote 0
                        • qyloxe
                          qyloxe @s.molinari last edited by

                          @s-molinari said in Quasar + Vagrant:

                          And now that WSL2 is out, there are no reasons left to stick with Vagrant on Windows 10. 🙂

                          oh, good days of Vagrant, I remember running 38 vms with three separate networks, dmz, bunch of software server clusters (db, web, app, queue, mail, search etc.). And all of that on a single developer machine. It felt like a magic 🙂 Till the deployment, which was hell mixed with nightmare.

                          Now everything is just simpler, and with Quasar clean architecture most of those ancient tasks are non-existent. Build, deploy, sync configuration, voila.

                          1 Reply Last reply Reply Quote 1
                          • First post
                            Last post