Commit Graph

98 Commits

Author SHA1 Message Date
Alex Dadgar
27048bb7fa events 2017-07-07 12:12:48 -07:00
Alex Dadgar
e1c631064a @jippi Changed my mind! Good suggestion 2017-07-07 12:12:48 -07:00
Alex Dadgar
da82a6e814 initial watcher 2017-07-07 12:07:08 -07:00
Michael Schurter
450e347708 Add support for go-getter modes
Fixes #2678
2017-07-06 10:45:44 -07:00
Michael Schurter
3f37be369d Move caonicalization from nomad/structs/ to api/ 2017-06-21 17:19:08 -07:00
Michael Schurter
3fddb05fc8 Implement DriverNetwork and Service.AddressMode
Ideally DriverNetwork would be fully populated in Driver.Prestart, but
Docker doesn't assign the container's IP until you start the container.

However, it's important to setup the port env vars before calling
Driver.Start, so Prestart should populate that.
2017-06-21 17:19:08 -07:00
Michael Schurter
7dac668adf Functional consul template env file support 2017-05-23 13:45:14 -07:00
Alex Dadgar
d606e98a6e New update block; still need to handle the upgrade path 2017-05-08 17:44:26 -07:00
Michael Schurter
7c67166510 Add TLSSkipVerify support to api and parser 2017-04-19 12:45:34 -07:00
Alex Dadgar
d212f6fe94 Track task start/finish time & improve logs errors
This PR adds tracking to when a task starts and finishes and the logs
API takes advantage of this and returns better errors when asking for
logs that do not exist.
2017-03-31 16:14:11 -07:00
Alex Dadgar
8b1359c2d0 Fix canonicalization of services 2017-03-01 15:30:01 -08:00
Michael Schurter
fe4537e1f3 Add Canonicalize test mimicing example job + template 2017-02-24 12:08:31 -08:00
Michael Schurter
d1794c1714 Missed initializing another field in Template! 2017-02-24 10:47:50 -08:00
Michael Schurter
24f5ec3e09 Template.Canonicalize wasn't initializing all fields 2017-02-24 10:31:05 -08:00
Alex Dadgar
c89d8247e6 Merge pull request #2302 from hashicorp/f-task-state-setup
Adding a task event for setup
2017-02-22 18:42:57 -08:00
Diptanu Choudhury
c80bdd9f5f Adding a task event for setup 2017-02-22 18:28:07 -08:00
Alex Dadgar
55e7ad7fd9 Remove defaulting from parse and fix parser tests
This PR removes defaulting from the parse, fixes some regressions that
existed as part of the parser refactor and fixes the tests.
2017-02-22 12:30:05 -08:00
Alex Dadgar
ee76b78922 rebase 2017-02-20 16:43:28 -08:00
Alex Dadgar
69aa5db628 Add leader and timezone to conversion 2017-02-20 16:36:41 -08:00
Diptanu Choudhury
5502a669e8 Added tests 2017-02-16 13:52:39 -08:00
Diptanu Choudhury
f551dcb83e Making the job spec return api.Job 2017-02-16 13:52:39 -08:00
Alex Dadgar
81c412cda0 Api Leader becomes a pointer 2017-02-13 10:43:33 -08:00
Alex Dadgar
edbc84087c Add Leader support to client 2017-02-10 17:55:19 -08:00
Alex Dadgar
a22f1647f9 Add leader task to api and server side 2017-02-10 16:57:47 -08:00
Alex Dadgar
9afa48310e Template destination file permissions.
This PR allows setting the file permissions of the rendered template.
2017-01-31 20:10:01 -08:00
Alex Dadgar
314435261d Rename dispatch_input to dispatch_payload 2017-01-25 21:27:44 -08:00
Alex Dadgar
248c069652 Merge pull request #2128 from hashicorp/f-dispatch
Nomad Constructor Jobs and Dispatch
2017-01-06 05:22:49 +08:00
Michael Schurter
750d59773c Rename InitializationMessage to DriverMessage 2016-12-20 11:51:09 -08:00
Alex Dadgar
e495eecece Rename structs 2016-12-14 14:28:43 -08:00
Michael Schurter
ee17940dfe Add Driver.Prestart method
The Driver.Prestart method currently does very little but lays the
foundation for where lifecycle plugins can interleave execution _after_
task environment setup but _before_ the task starts.

Currently Prestart does two things:

* Any driver specific task environment building
* Download Docker images

This change also attaches a TaskEvent emitter to Drivers, so they can
emit events during task initialization.
2016-12-02 11:03:48 -08:00
Alex Dadgar
22d494f812 Dispatch structs 2016-11-23 15:03:13 -08:00
Alex Dadgar
51831f92dd Merge pull request #1840 from hashicorp/f-kill-fail
Change how we mark tasks as failed and allow consul-template to fail tasks
2016-10-24 13:40:52 -07:00
Michael Schurter
4d3187bc7e Remove disk usage enforcement
Many thanks to @iverberk for the original PR (#1609), but we ended up
not wanting to ship this implementation with 0.5.

We'll come back to it after 0.5 and hopefully find a way to leverage
filesystem accounting and quotas, so we can skip the expensive polling.
2016-10-21 13:55:51 -07:00
Alex Dadgar
f130c8a894 Change how we mark tasks as failed and allow consul-template to fail tasks 2016-10-20 17:27:16 -07:00
Alex Dadgar
e34902ae8a Large refactor of task runner and Vault token rehandling 2016-10-18 11:24:20 -07:00
Alex Dadgar
ebef11e6b0 Struct/api/parsing 2016-10-18 11:24:20 -07:00
Alex Dadgar
af517b3d37 Task runner sends signals 2016-10-10 15:09:00 -07:00
Alex Dadgar
d200a835c9 Fix handling of restart in TaskEvents 2016-10-06 15:06:54 -07:00
Alex Dadgar
b976633e4d Start of integration 2016-10-06 15:05:49 -07:00
Diptanu Choudhury
c29861b418 Getting snapshot of allocation from remote node (#1741)
* Added the alloc dir move

* Moving allocdirs when starting allocations

* Added the migrate flag to ephemeral disk

* Stopping migration if the allocation doesn't need migration any more

* Added the GetAllocDir method

* refactored code

* Added a test for alloc runner

* Incorporated review comments
2016-10-03 09:59:57 -07:00
Alex Dadgar
56b9767f8e Add template structs 2016-09-26 15:36:11 -07:00
Alex Dadgar
a81de3a161 Add env 2016-09-21 16:37:04 -07:00
Alex Dadgar
d49dda45e3 Merge pull request #1713 from hashicorp/f-alloc-runner-vault
Vault integration in client
2016-09-20 16:15:55 -07:00
Alex Dadgar
7f608add4f alloc-status 2016-09-14 18:27:13 -07:00
Diptanu Choudhury
396e45629b Renaming LocalDisk to EphemeralDisk (#1710)
Renaming LocalDisk to EphemeralDisk
2016-09-14 15:43:42 -07:00
Diptanu Choudhury
183294644e Fixed api tests 2016-08-25 22:10:25 -05:00
Diptanu Choudhury
0628fee7a8 Implemented job spec parsing for sticky volumes 2016-08-24 13:51:15 -05:00
Marin
43e17c4f95 api/tasks.go: add check initial_status 2016-08-23 14:09:42 -07:00
Alex Dadgar
1c45799c49 Merge pull request #1580 from hashicorp/f-disk-usage-monitoring
Monitor and enforce shared allocation directory disk usage
2016-08-23 09:49:53 -07:00
Diptanu Choudhury
5036f24591 Attempting to fix alloc status test 2016-08-22 15:07:49 -05:00