Mahmood Ali
e506ebbc24
Merge pull request #4845 from hashicorp/r-exec-refactor
...
Update exec driver to match rawexec
2018-11-12 20:59:32 -05:00
Danielle Tomlinson
880e5015f2
rawexec: Only use cgroups when running as root.
...
If Nomad is not running as root, we should not try to use cgroups for pid
freezing.
This originally was implemented pre-driver-support in
https://github.com/hashicorp/nomad/blob/v0.8.6/client/driver/raw_exec.go#L120-L130
2018-11-10 06:45:11 -08:00
Mahmood Ali
9c76a7d9b8
handle nil resources limits
...
Config may not express resource constraints on the job!
2018-11-09 15:52:44 -05:00
Mahmood Ali
1ed53ca478
shorter health descriptions
2018-11-08 10:00:49 -08:00
Mahmood Ali
032f86bc78
Add a helper functions for checking unix root
2018-11-08 10:00:49 -08:00
Mahmood Ali
21d126cd68
Update exec driver to match rawexec
...
Update exec driver with latest patterns used by rawexec, and eliminate
accidental diffs.
2018-11-08 10:00:49 -08:00
Alex Dadgar
a7ca737fb6
review comments
2018-11-07 11:31:52 -08:00
Alex Dadgar
204ca8230c
Device manager
...
Introduce a device manager that manages the lifecycle of device plugins
on the client. It fingerprints, collects stats, and forwards Reserve
requests to the correct plugin. The manager, also handles device plugins
failing and validates their output.
2018-11-07 10:43:15 -08:00
Mahmood Ali
32283b2a66
reconcile java with latest patterns
2018-11-06 12:49:29 -08:00
Mahmood Ali
467360954a
driver/java: support non-linux targets
...
Java driver supports non-linux targets, so LinuxResources fields isn't
guaranteed to be not-nil.
2018-11-06 12:41:39 -08:00
Mahmood Ali
e64ef839b8
Reconcile with latest master patterns
2018-11-06 12:41:39 -08:00
Mahmood Ali
c3881bd8d1
add java driver tests
2018-11-06 12:41:39 -08:00
Mahmood Ali
4f525d0a17
Implement java driver
2018-11-06 12:41:39 -08:00
Michael Schurter
392d548b85
Merge pull request #4828 from hashicorp/b-restore
...
Implement client agent restarting
2018-11-05 18:50:15 -06:00
Michael Schurter
2bbd88888c
client: first pass at implementing task restoring
...
Task restoring works but dead tasks may be restarted
2018-11-05 12:32:05 -08:00
Mahmood Ali
a17521475d
Merge pull request #4826 from hashicorp/b-driver-exec-tweaks-20181031
...
Register exec driver plugin among some fixes
2018-11-02 10:11:05 -04:00
Mahmood Ali
dc0fc442ab
add plugin config
2018-11-02 08:51:23 -04:00
Michael Schurter
83db3e6a50
rkt: standardize names/code
2018-11-01 15:53:07 -07:00
Michael Schurter
1a7fb51285
rawexec: standardize names/code
2018-11-01 15:53:07 -07:00
Michael Schurter
5a5d52023d
qemu: standardize names/code
2018-11-01 15:53:07 -07:00
Michael Schurter
3c5e606ef6
drivers/mock: standardize names/code
2018-10-31 11:52:51 -07:00
Mahmood Ali
9a45837c4e
Register exec driver plugin among some fixes
...
Namely, remove the `enabled` configuration flag, as it's specific to
`raw_exec` driver. Also, pass resource limits to underlying call.
2018-10-31 13:55:59 -04:00
Michael Schurter
d3dafc9761
mock_driver: match other's fingerprint message
2018-10-30 17:38:23 -07:00
Michael Schurter
2a38f575c0
rkt: fix race, register by default, fix fingerprint
2018-10-30 17:37:00 -07:00
Michael Schurter
5b0b75e1ee
qemu: fix fingerprint description and handle race
2018-10-30 17:34:08 -07:00
Michael Schurter
6f4a28a7c2
rawexec: fix fingerprint results and tests
...
In tests:
* always cleanup (Kill) the harness
* don't call SetConfig more than once (a race)
* avoid cgroups to allow running without being root
2018-10-30 17:16:22 -07:00
Michael Schurter
616801417c
rawexec: fix race around h.procState
2018-10-30 17:15:47 -07:00
Michael Schurter
9fa53565ad
drivers: remove stutter from exported driver names
...
Also fix a comment on the logger that got copy/pasted around.
2018-10-30 14:05:31 -07:00
Michael Schurter
fc320906aa
qemu: fix build and register by default
...
API changes had broken the build.
2018-10-29 22:10:37 -07:00
Nick Ethier
3fcf8ba7e6
Merge pull request #4795 from hashicorp/f-plugin-config
...
Pass client configuration to plugins through loader
2018-10-29 18:42:27 -07:00
Nick Ethier
bda3b1d3b3
rename NomadConfig to ClientAgentConfig
2018-10-29 21:34:34 -04:00
Preetha Appan
68991d8acb
Merge branch 'f-driver-plugin-qemu' of github.com:hashicorp/nomad into f-driver-plugin-qemu
2018-10-25 13:51:58 -05:00
Preetha Appan
bfff771416
remove driver config struct from qemu driver since its not used
2018-10-25 13:51:06 -05:00
Michael Schurter
48d25dbef1
Fix hclog log line formatting
...
Co-Authored-By: preetapan <preetha@hashicorp.com>
2018-10-25 13:47:17 -05:00
Preetha Appan
95a1637741
Fix imports
2018-10-25 13:45:44 -05:00
Michael Schurter
ca151a7828
Fix copy pasted comment
...
Co-Authored-By: preetapan <preetha@hashicorp.com>
2018-10-25 13:43:29 -05:00
Michael Schurter
c85b90f1e4
remove newline
...
Co-Authored-By: preetapan <preetha@hashicorp.com>
2018-10-25 13:42:20 -05:00
Michael Schurter
66c15e3a67
update comment
...
Co-Authored-By: preetapan <preetha@hashicorp.com>
2018-10-25 13:41:24 -05:00
Michael Schurter
9ca6c998c7
Remove unnecessary return
...
Co-Authored-By: preetapan <preetha@hashicorp.com>
2018-10-25 13:40:28 -05:00
Michael Schurter
fc7ba5e79d
remove unnecessary return
...
Co-Authored-By: preetapan <preetha@hashicorp.com>
2018-10-25 13:40:15 -05:00
Nick Ethier
9916b9e0ce
drivers: update SetConfig to handle driver client config
2018-10-18 23:32:17 -04:00
Michael Schurter
af3e9adf2f
Update drivers/qemu/driver.go
2018-10-17 17:42:01 -05:00
Preetha Appan
93eb048b87
QEMU driver plugin
2018-10-17 11:43:15 -05:00
Alex Dadgar
4b694b2dec
Merge pull request #4793 from hashicorp/b-no-cty
...
Do not use cty in drivers
2018-10-16 20:04:41 -07:00
Nick Ethier
823a6c8d6c
update rkt and exec setconfig funcs
2018-10-16 23:00:26 -04:00
Nick Ethier
65adb80ebf
plumb NomadConfig into plugins
2018-10-16 22:47:22 -04:00
Nick Ethier
b657c3909a
drivers/exec: better fingerprinting and detection on non linux
2018-10-16 22:45:33 -04:00
Nick Ethier
d94b631b6b
drivers/exec: add exec implementation
2018-10-16 22:45:28 -04:00
Alex Dadgar
88c1885044
Do not use cty in drivers
2018-10-16 17:17:07 -07:00
Michael Schurter
838ddf4d4a
fix linter errors
2018-10-16 16:56:57 -07:00