Giter Site home page Giter Site logo

Comments (7)

rmahoney-bl avatar rmahoney-bl commented on July 28, 2024

I second this request. It would be great if, based on the configuration in the Vagrantfile, gatling-rsync-auto would simply begin in the background.

There are two advantages of this approach:

  1. saves unnecessary step / terminal window
  2. good for beginners, as this aspect of project synchronization is abstracted away

from vagrant-gatling-rsync.

smerrill avatar smerrill commented on July 28, 2024

I would also like to do this because I completely agree that just running it on start would be great, especially for beginners.

You can run vagrant gatling-rsync-auto via a plugin like vagrant-host-shell, and maybe via vagrant-triggers, but these options are suboptimal, since the vagrant up never registers as finishing, so you cannot do other Vagrant commands in other windows.

I took a look at this today to see if I could get a quick proof-of-concept working and I couldn't quite get it wired up in a couple hours.

I'll try to dig in a bit more over the New Years weekend to see if this is possible (and if the same issues with vagrant up never finishing persist if I get it working.)

from vagrant-gatling-rsync.

rmahoney-bl avatar rmahoney-bl commented on July 28, 2024

@smerrill thanks so much! This is just icing on the cake of an excellent plugin :)

from vagrant-gatling-rsync.

FractalizeR avatar FractalizeR commented on July 28, 2024

Well, that would be great. I also looking for a way to start it up automatically.

from vagrant-gatling-rsync.

jordanambra avatar jordanambra commented on July 28, 2024

FWIW, I ended up doing something similar with a combo of vagrant-triggers and a shell script that runs with an & at the end of the command. It's not really enterprise-worthy, but I ended up with this. Save it as a file, make it executable, and run it in a block from vagrant-trigger.

#!/bin/bash

ACTION="$1"

if [[ "$ACTION" == "start" ]]
then
    echo "Starting file sync from host to Vagrant VM"
    vagrant rsync-auto &> /dev/null &
else
    echo "Stopping file sync with Vagrant VM"
    ps ax | grep rsync-auto | grep -v grep | awk '{ print $1 }' | xargs kill
fi

from vagrant-gatling-rsync.

smerrill avatar smerrill commented on July 28, 2024

I have a proof-of-concept working for this feature pushed to RubyGems as 0.2.0.beta.1.

I'd love some help with testing it. To do so, you will need to opt in to automatic syncing by putting the following in your Vagrantfile.

if Vagrant.has_plugin?("vagrant-gatling-rsync")
  config.gatling.rsync_on_startup = true
end

Then, install the beta gem and start up an environment.

$ vagrant plugin install vagrant-gatling-rsync --plugin-version '0.2.0.beta.1'
$ vagrant up

It will automatically start syncing on a vagrant up or a vagrant reload.

I think that multi-box environments may not work properly if you start a specific machine, and I'm still considering if it should default to running the sync automatically; if so, I might only default it to true if there are synced folders defined.

from vagrant-gatling-rsync.

smerrill avatar smerrill commented on July 28, 2024

This is now in the 0.9.0 release. Please try it out.

from vagrant-gatling-rsync.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.