Commit graph

141 commits

Author SHA1 Message Date
Julien Mailleret
9bac169862
use files permissions from official package 2019-09-18 10:57:07 +02:00
Julien Mailleret
6a1b886753
use default permissions from official package for plugin directory 2019-09-18 10:53:43 +02:00
Julien Mailleret
ffc6d99915
clean es_xpack_custom_url variable wich is no more used
This was used to define url to download X-Pack but X-Pack is now embedded in Elasticsearch since 6.3
2019-09-16 10:46:43 +02:00
Julien Mailleret
0f601259c6
clean es_xpack_conf_subdir variable
This variable was added to manage specific x-pack dir with version < 6.3
2019-09-16 10:43:32 +02:00
Julien Mailleret
718b3936f1
remove http.port recommendation 2019-07-12 11:59:07 +02:00
Julien Mailleret
2cb020a4c2
Remove multi instances support (#566)
* remove multi instances support
The goal is to stop supporting installation of more than one node in the same host. This commit update the Ansible role README documentation and remove the multi instances kitchen test.

* remove systemd and init.d templates
As we no more need to support more than one node on the same host, we no more need to override init files provided by elasticsearch official packages.

* remove file script feature
File scripts have been removed since elasticsearch 6.0 (https://www.elastic.co/guide/en/elasticsearch/reference/6.0/breaking_60_scripting_changes.html#_file_scripts_removed)

* remove custom user and custom group
ES_USER and ES_GROUP settings are no longer supported (https://www.elastic.co/guide/en/elasticsearch/reference/6.0/breaking_60_packaging_changes.html#_configuring_custom_user_and_group_for_package_is_no_longer_allowed)

* add upgrade procedure

* use same task for license activation with and without authentication
2019-06-03 14:18:09 +02:00
Julien Mailleret
a879b74def
[xpack] use elasticsearch default xpack features (#560)
- Stop forcing es_xpack_features variable in order to let elasticsearch install default features described in http://localhost:9200/_xpack
- Change xpack test scope to be able to test default xpack install
  - xpack scenario will test xpack install with default features
  - xpack upgrade scenario will fully test security feature
  - oss-to-xpack-upgrade will test installing only other specific features
- Cleanup some duplicate serverspec tests
- Remove `system_key`feature (deprecated in 5.6 and removed in 6.0 - [Breaking Changes 6.0.0](https://www.elastic.co/guide/en/elasticsearch/reference/6.0/breaking-6.0.0-xes.html))
- Cleanup some ansible code (especially in `when` conditions)
2019-05-29 12:10:11 +02:00
Julien Mailleret
1585ec2c1c
remove file script feature
File scripts have been removed since elasticsearch 6.0 (https://www.elastic.co/guide/en/elasticsearch/reference/6.0/breaking_60_scripting_changes.html#_file_scripts_removed)
2019-05-27 18:16:50 +02:00
Julien Mailleret
a1c81884e2
[7.x] add support for elasticsearch 7.x and remove support for 5.x (#558)
- add support for elasticsearch 7.x
- remove support for elasticsearch 5.x
- update kitchen-ansible configuration (install ansible and jmespath dependencies using os repositories)
- replace geoip plugin in tests as this one is now embeded in elasticsearch since 6.7.0 (cf. https://www.elastic.co/guide/en/elasticsearch/plugins/6.7/ingest-geoip.html)
- update discovery configuration for 7.x (in ES 7.x, discovery.zen.ping.unicast.hosts is replaced by discovery.seed_hosts and transport.tcp.port is replaced by transport.port, also discovery.seed_hosts is disabled on master nodes to avoid "master_not_discovered_exception" error when creating templates in the same play)
- update index template structure for 7.x 
- update security realms settings for 7.x (cf. https://www.elastic.co/guide/en/elasticsearch/reference/current/breaking-changes-7.0.html#include-realm-type-in-setting)
2019-05-09 09:06:02 +02:00
Michael Russell
5126dbc5e8
Actually remove the unused RedHat repository 2019-01-02 10:06:47 +01:00
Michael Russell
afc2fe74ae
Switch to vanilla docker images and add Ubuntu 18.04 and Debian 9 2018-11-26 15:26:57 +01:00
Michael Russell
e147478542
Fix the tested path.conf for 5.x
This was previously passing because our CI configuration was actually
testing 6.x instead of 5.x. Luckily this is the only problem which
hadn't been caught since this was introduced.
2018-08-28 12:24:10 +02:00
Michael Russell
95c0bff835
Fix path.data content test for when there are multiple paths 2018-06-19 22:11:46 +02:00
Michael Russell
e1cfb90f5d
Clean up remaining yml test definitions 2018-06-19 21:36:41 +02:00
Michael Russell
c325ff79fa
Move all shared tests into the shared test helper 2018-06-19 21:17:10 +02:00
Michael Russell
9673fe4679
Make sure shared tests work for RedHat and Debian 2018-06-19 19:30:40 +02:00
Michael Russell
433ed7f5e3
Master is called master and node is called node 2018-06-19 17:20:48 +02:00
Michael Russell
f53e639797
Fix curl_json/json_curl typo 2018-06-19 17:17:11 +02:00
Michael Russell
c8197ee82a
Move generic tests into a shared spec file 2018-06-19 12:15:10 +02:00
Michael Russell
da58c5f0dd
Move to new testing suite names
This commit is just moving the tests to their new names. The config,
packge and issue test suites have been removed and the tests from these
will be incorporated into the oss and xpack tests.

oss: Standard elasticsearch-oss role with idempotency test

oss-upgrade: Upgrade from previous minor version oss to current minor version oss

oss-to-xpack-upgrade: Upgrade from previous minor version oss to current minor version xpack

xpack: Standard elasticsearch (with xpack) role with idempotency test

xpack-upgrade: Upgrade from previous minor version xpack to current minor version xpack

multi: Tests multiple instances of elasticsearch on a single machine
2018-06-19 10:39:16 +02:00
Michael Russell
d451d27723
Only symlink systemd file for systemd systems 2018-06-18 07:37:51 +02:00
Michael Russell
23e336833a
This file should now be a symbolic link, temporarily removing to let the
other tests run
2018-06-15 17:37:53 +02:00
Michael Russell
2c8ce3bb2d
Add test for upgrading from previous version of oss to current 2018-06-15 17:22:18 +02:00
Michael Russell
4c35794b76
Add jenkins test matrix yml definition
This allows us to control and modify the jenkins matrix job via the pull
request flow instead of needing to sync changes in the jenkins
configuration.
2018-06-15 10:59:00 +02:00
Michael Russell
e9a267ec55
Add authentication back to the plugins check for xpack (got lost during
copy paste refactoring)
2018-06-15 07:40:35 +02:00
Michael Russell
ea6f1c2088
Remove invalid tests for roles.yml, system_key, user_roles and users
All of these were not actually defined in the final play of the testing
role however were leftover by the previous run or default install. The
changes in 6.3 moved the locations of these files to a different
directory causing these tests to fail (as they should be doing!)
2018-06-14 20:22:05 +02:00
Michael Russell
3ab3b1d05c
Add xpack license for issue-test since security is not available in the
trial license
2018-06-14 18:41:41 +02:00
Michael Russell
77d47e3235
Don't use the 'x-pack' subdir now that x-pack is part of core 2018-06-14 16:33:40 +02:00
Michael Russell
d8cf1d1f66
Explicitly set xpack.security.enabled: True
Only run test for checking if X-Pack is a plugin for 6.3 because it is
now installed into core
2018-06-14 15:48:18 +02:00
Michael Russell
06a8c5c41b
Remove es_package_name hard coding since this is dynamically detected now 2018-06-14 15:06:24 +02:00
Michael Russell
bbc5e0603d
Abstract 6.3 changes into a separate task to reduce all of the jinja one
liner complexity

Set ES_PATH_CONF when installing so upgrading from 6.2 to 6.3 works as
expected
2018-06-14 14:44:31 +02:00
Michael Russell
715bd8591e
Use final 6.3.0 release instead of snapshot 2018-06-13 21:34:32 +02:00
Michael Russell
929a860fd3
Specify that these tests are still using the oss package 2018-06-13 10:03:40 +02:00
Michael Russell
6d82cf3142
WIP: 6.3 support 2018-06-13 08:29:45 +02:00
Michael Russell
917fc7fcfc
Look at the results from the http request instead of checking that the
json matches an md5 hash. This was causing flaky tests because the
order of the users in the test doing `curl -s localhost:9200/_xpack/security/user -u
es_admin:changeMeAgain` is not consistent which caused random failures.
Now if it does fail we will actually know the reason why:
```
 security users
    should have the elastic user
    should have the kibana user (FAILED - 1)
    should have the kibana_server user
    should have the logstash user
  logstash_system access check
    should be reported as version 6.2.4

Failures:

  1) Xpack Tests security users should have the kibana user
     Failure/Error: expect(result['kibana']['username']).to eq('kibana4')

       expected: "kibana4"
            got: "kibana"
```

The failure output use to look like:

```
Failures:

  1) Xpack Tests Command "curl -s localhost:9200/_xpack/security/user -u es_admin:changeMeAgain | md5sum | grep b6a1293c343e745a508c74778c9be8bb" exit_status should eq 0
     Failure/Error: its(:exit_status) { should eq 0 }

       expected: 0
            got: 1

       (compared using ==)
       /bin/sh -c curl\ -s\ localhost:9200/_xpack/security/user\ -u\ es_admin:changeMeAgain\ \|\ md5sum\ \|\ grep\ b6a1293c343e745a508c74778c9be8bb
```
2018-05-17 08:39:13 +02:00
Michael Russell
38982ba6ad
Only change name to x-pack-core for 6.2 and above 2018-02-22 11:14:25 +01:00
Michael Russell
d9d54917bd
X-pack plugin has been renamed to x-pack-core 2018-02-22 10:01:16 +01:00
Michael Russell
fe0fc4b430
Bump default version to 6.2.2 and 5.6.8 2018-02-21 21:09:15 +01:00
Michael Russell
fecf5164c8
Test the returned results rather than an md5 hash of the json. These
tests were breaking on 6.x because certain fields have been
moved/changed
2018-02-01 11:59:32 +01:00
Michael Russell
bfced19152
Fix paths that came in from mass copy paste errors 2018-01-31 14:39:55 +01:00
Michael Russell
c30c263aa3
Set older version for 5.x and 6.x to test that upgrading works as
expected
2018-01-31 14:39:20 +01:00
Michael Russell
29f2c6a17e
Use default es_version supplied by playbook 2018-01-31 14:39:07 +01:00
Michael Russell
9eae7e3a3d
Standard xpack doesn't have es_plugins defined so just test the x-pack
plugin
2018-01-31 12:59:13 +01:00
Michael Russell
3bbd6f3e07
Dynamically generate xpack url based on the version 2018-01-31 12:09:15 +01:00
Michael Russell
b0083ae293
Fix path config to match the node name 2018-01-31 12:07:32 +01:00
Michael Russell
043c1bff69
6.x should not have path.conf present 2018-01-31 08:17:44 +01:00
Michael Russell
94b059080b
Update tests to work with dynamic es_versions 2018-01-31 08:14:24 +01:00
Michael Russell
db1079ee4d
Rename integration tests to remove hardcoded 5.x version 2018-01-22 16:00:13 +01:00
Dale McDiarmid
7ab416c782 Move fil realm reserved user check earlier, Move template and license after naitve realm 2017-09-20 22:58:17 +01:00
Dale McDiarmid
e9a6f74d09 Fix for issue #369 2017-09-19 20:11:09 +01:00