Commit Graph

53 Commits

Author SHA1 Message Date
Alex Dadgar
80c4b03f07 fix vet 2017-07-22 22:43:33 -07:00
Alex Dadgar
70040f2574 fingerprinters 2017-07-22 20:38:03 -07:00
Alex Dadgar
4c7c3c45e2 Merge branch 'master' of github.com:hashicorp/nomad 2017-07-22 19:48:54 -07:00
Alex Dadgar
22c5999c09 darwin test fixes 2017-07-22 19:48:47 -07:00
Alex Dadgar
08c2ba9bc6 Parallel client tests (#2890)
* alloc_runner

* Random tests

* parallel task_runner and no exec compatible check

* Parallel client

* Fail fast and use random ports

* Fix docker port mapping

* Make concurrent pull less timing dependant

* up parallel

* Fixes

* don't build chroots in parallel on travis

* Reduce parallelism on travis with lxc/rkt

* make java test app not run forever

* drop parallelism a little

* use docker ports that are out of the os's ephemeral port range

* Limit even more on travis

* rkt deadline
2017-07-22 19:04:36 -07:00
Alex Dadgar
789a5072a9 Parallel 2017-07-21 12:06:39 -07:00
Michael Schurter
8a7df57227 Test driver network advertisement and checks 2017-06-21 17:19:08 -07:00
Michael Schurter
b048c9eefb Fix java tests 2017-01-20 14:12:30 -08:00
Michael Schurter
269b3c7e14 Merge pull request #2186 from hashicorp/f-driver-cleanup
Add Cleanup method to Driver interface
2017-01-20 13:02:14 -08:00
Alex Dadgar
9206446a8d Support setting class_path and class name.
This PR enhances the java driver to allow setting the class path and
class name to run. It also fixes an issue that would make the Java
driver attempt to chroot regardless of operating system (this never
effected a released version of Nomad).
2017-01-13 16:03:11 -08:00
Michael Schurter
33c015bcc7 Add Cleanup method to Driver interface
Cleanup can be used for cleaning up resources created by drivers to run
a task. Initially the Docker driver is the only user (to remove
downloaded images).
2017-01-11 17:23:33 -08:00
Michael Schurter
de7351b959 Move chroot building into TaskRunner
* Refactor AllocDir to have a TaskDir struct per task.
* Drivers expose filesystem isolation preference
* Fix lxc mounting of `secrets/`
2017-01-05 16:31:49 -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
0b65a5f95d Executor + Java/Raw Exec/Exec 2016-10-10 11:47:04 -07:00
Alex Dadgar
4bae54741e Secret dir materialized in alloc/task directory 2016-09-02 12:44:05 -07:00
Diptanu Choudhury
e93ff0af02 Fixed a java test 2016-08-23 16:51:09 -05:00
Diptanu Choudhury
938d512f49 Not running tests parallal 2016-08-11 21:53:27 -07:00
Sean Chittenden
572925a5fa Fix test for non-Linux platforms.
The following tests now check a whitelist for whether or not their
driver is present or not, or if the OS is supported or not.

* `TestAllocDir_MountSharedAlloc`
* `TestClient_Drivers_InWhitelist` (`exec` driver)
* `TestClient_Drivers` (`exec` driver)
* `TestJavaDriver_Fingerprint` (`java` driver)
2016-07-10 15:19:49 -07:00
Miquel Sabaté Solà
b41608df51 client/driver: added more tests
Signed-off-by: Miquel Sabaté Solà <msabate@suse.com>
2016-03-24 08:47:23 +01:00
Alex Dadgar
4c1be8e637 Get tests to pass 2016-03-15 13:28:57 -07:00
Diptanu Choudhury
be55af6d90 Fixed some java tests 2016-02-24 23:54:01 -08:00
Diptanu Choudhury
10c3685a83 Fixed the fingerprinter test 2016-02-18 11:34:17 -08:00
Diptanu Choudhury
e92d0a65f8 Enabling cgroups and chroot on linux 2016-02-18 09:49:11 -08:00
Alex Dadgar
48a97e0a9e fix java test 2016-02-17 10:04:19 -08:00
Diptanu Choudhury
d94c28b39c Fixed more tests 2016-02-10 13:54:54 -08:00
Diptanu Choudhury
443acc1520 Fixing the id generation logic for the java and qemu drivers 2016-02-04 17:00:40 -08:00
Alex Dadgar
e0c23ec2cd Use TestMultiplier on all waits 2016-01-21 15:24:24 -08:00
Alex Dadgar
e91abac0f6 Fix a bunch of tests
Up timeouts

trusty travis beta

Increase timeouts
2016-01-20 16:03:53 -08:00
Alex Dadgar
dccbc0320b Fix tests 2016-01-11 09:58:31 -08:00
Chris Hines
ffda9d71d4 Speed up tests by allowing parallel execution. 2015-11-25 15:56:55 -05:00
Alex Dadgar
7357979089 Revert "Revert "Make drivers take arguments as a list and not as a string"" 2015-11-18 15:16:42 -08:00
Alex Dadgar
d666f5bde1 Revert "Make drivers take arguments as a list and not as a string" 2015-11-18 13:46:43 -08:00
Alex Dadgar
62a0c5d14c Rebase 2015-11-18 12:30:35 -08:00
Chris Bednarski
1d1e4bdd08 Merge branch 'master' into f-port-labels 2015-11-16 16:02:38 -08:00
Alex Dadgar
f4b461f97a Track Task State in the client and capture Wait results 2015-11-16 15:14:21 -08:00
Diptanu Choudhury
0d69778873 Fixed compilation issues with driver tests 2015-11-16 13:10:57 -08:00
Alex Dadgar
a355e5889c Enable Open tests for Exec/Java 2015-11-10 16:59:52 -08:00
Clint Shryock
0fe2ea9b04 add checksums to tests, formatting after rebase 2015-11-05 09:23:45 -06:00
Clint Shryock
add12a6a00 refactor drivers to use new getter 2015-11-05 08:55:30 -06:00
Alex Dadgar
13ea9bc9ff Make a basic executor that can be shared and fix some fingerprinting/tests 2015-11-03 12:47:48 -08:00
Alex Dadgar
6cf8eeb216 Small improvements 2015-11-03 10:50:30 -08:00
Abhishek Chanda
1a3f79c755 Actually append jvm opts to the CLI
- Also adds a test
2015-10-16 22:45:16 +00:00
Chris Bednarski
2801e7d1e1 Fingerprint test should now behave correctly when the executor is not installed; fix some go vet issues 2015-10-06 16:33:02 -07:00
Chris Bednarski
723b55c049 Merge branch 'master' into b-docker-fixes
Conflicts:
	client/driver/docker_test.go
	client/driver/java_test.go
	client/driver/qemu_test.go
2015-09-25 18:35:23 -07:00
Alex Dadgar
04094cfb40 Small test cleanup 2015-09-25 17:55:29 -07:00
Chris Bednarski
f2dd5cac18 Added guards to tests so we can more gracefully degrade the test suite when thing are not installed 2015-09-25 16:49:26 -07:00
Chris Bednarski
559462b49f Added basic resources to exec/java tests so each test has cpu, ram, and network 2015-09-25 16:49:18 -07:00
Alex Dadgar
8a5e65e27a Merge qemu test 2015-09-25 16:49:14 -07:00
Chris Bednarski
0e00b5fbf7 Updated Qemu and tests to use DriverContext 2015-09-09 18:38:52 -07:00
Chris Bednarski
f911a24837 Added config to drivers; needed for docker driver to get the socket endpoint 2015-09-08 12:43:02 -07:00