| OLD | NEW |
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 # | 2 # |
| 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
| 4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
| 6 | 6 |
| 7 """Create and copy update image to target host. | 7 """Create and copy update image to target host. |
| 8 | 8 |
| 9 auto-update and devserver change out from beneath us often enough | 9 auto-update and devserver change out from beneath us often enough |
| 10 that despite having to duplicate a litte code, it seems that the | 10 that despite having to duplicate a litte code, it seems that the |
| (...skipping 432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 443 xmlns = 'http://www.google.com/update2/response' | 443 xmlns = 'http://www.google.com/update2/response' |
| 444 payload_success_template = """<?xml version="1.0" encoding="UTF-8"?> | 444 payload_success_template = """<?xml version="1.0" encoding="UTF-8"?> |
| 445 <gupdate xmlns="%s" protocol="2.0"> | 445 <gupdate xmlns="%s" protocol="2.0"> |
| 446 <daystart elapsed_seconds="%s"/> | 446 <daystart elapsed_seconds="%s"/> |
| 447 <app appid="{%s}" status="ok"> | 447 <app appid="{%s}" status="ok"> |
| 448 <ping status="ok"/> | 448 <ping status="ok"/> |
| 449 <updatecheck | 449 <updatecheck |
| 450 codebase="%s" | 450 codebase="%s" |
| 451 hash="%s" | 451 hash="%s" |
| 452 sha256="%s" | 452 sha256="%s" |
| 453 IsDelta="true" |
| 453 needsadmin="false" | 454 needsadmin="false" |
| 454 size="%s" | 455 size="%s" |
| 455 status="ok"/> | 456 status="ok"/> |
| 456 </app> | 457 </app> |
| 457 </gupdate> | 458 </gupdate> |
| 458 """ | 459 """ |
| 459 payload_failure_template = """<?xml version="1.0" encoding="UTF-8"?> | 460 payload_failure_template = """<?xml version="1.0" encoding="UTF-8"?> |
| 460 <gupdate xmlns="%s" protocol="2.0"> | 461 <gupdate xmlns="%s" protocol="2.0"> |
| 461 <daystart elapsed_seconds="%s"/> | 462 <daystart elapsed_seconds="%s"/> |
| 462 <app appid="{%s}" status="ok"> | 463 <app appid="{%s}" status="ok"> |
| (...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 714 | 715 |
| 715 if child: | 716 if child: |
| 716 os.kill(child, 15) | 717 os.kill(child, 15) |
| 717 | 718 |
| 718 cros_env.Info('Server exiting with status %d' % exit_status) | 719 cros_env.Info('Server exiting with status %d' % exit_status) |
| 719 sys.exit(exit_status) | 720 sys.exit(exit_status) |
| 720 | 721 |
| 721 | 722 |
| 722 if __name__ == '__main__': | 723 if __name__ == '__main__': |
| 723 main(sys.argv) | 724 main(sys.argv) |
| OLD | NEW |