madecoste / swarming

Automatically exported from code.google.com/p/swarming
Apache License 2.0
0 stars 1 forks source link

Deploy the swarm_bot code as a zip, e.g. make swam_bot.zip directly executable #109

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Right now when deploying a new swarming bot, the deployment script downloads a 
zip and extract it locally. This creates problem when upgrading the python code 
because stale .pyc files could be left dangling and when a module is renamed or 
moved in a new directory, the old one remains on the bot.

The tricky issue is that there is 3 runnable scripts one the bot:
- start_slave.py which defines custom dimensions and special behavior like 
rebooting automatically. For example 
https://chromium.googlesource.com/chromium/tools/build.git/+/master/scripts/tool
s/swarm_bootstrap/start_slave.py
- slave_machine.py which does the server<->client interaction
- local_test_runner.py that takes care of running the scripts as requested by 
the client in their request.

The separation should remain, since it's useful when local_test_runner.py 
hangs, which happened in the past in particular configurations.

So this means swarm_bot.zip must key its execution to run one or the other 
script depending on the initial argument. This means all the current bot will 
have to run a one-off update so they run the script correctly afterward. It's 
short term pain to make it much simpler afterward.

Original issue reported on code.google.com by maruel@chromium.org on 23 May 2014 at 7:22

GoogleCodeExporter commented 9 years ago

Original comment by maruel@chromium.org on 23 May 2014 at 7:31

GoogleCodeExporter commented 9 years ago

Original comment by maruel@chromium.org on 23 May 2014 at 7:34

GoogleCodeExporter commented 9 years ago
Bumping priority since it'll become harder and harder to deploy as the 
utilisation goes up.

Original comment by maruel@chromium.org on 26 May 2014 at 3:06

GoogleCodeExporter commented 9 years ago

Original comment by maruel@chromium.org on 29 May 2014 at 1:59

GoogleCodeExporter commented 9 years ago
It works, it's awesome.

Original comment by maruel@chromium.org on 5 Jun 2014 at 4:09