Adoptable Cookbooks List

Looking for a cookbook to adopt? You can now see a list of cookbooks available for adoption!
List of Adoptable Cookbooks

Supermarket Belongs to the Community

Supermarket belongs to the community. While Chef has the responsibility to keep it running and be stewards of its functionality, what it does and how it works is driven by the community. The chef/supermarket repository will continue to be where development of the Supermarket application takes place. Come be part of shaping the direction of Supermarket by opening issues and pull requests or by joining us on the Chef Mailing List.

Select Badges

Select Supported Platforms

Select Status

RSS

aet (11) Versions 5.1.3

Installs/Configures aet

Policyfile
Berkshelf
Knife
cookbook 'aet', '~> 5.1.3', :supermarket
cookbook 'aet', '~> 5.1.3'
knife supermarket install aet
knife supermarket download aet
README
Dependencies
Changelog
Quality 33%

AET Cookbook

This cookbook prepare virtual machine for Automated Exploratory Tests (AET).

It may be used to quickly create platform for AET demo
or to setup an environment for AET development.
Required artifacts are downloaded by this cookbook
from AET GitHub releases page.

Supported Platforms

Because this cookbook is used for demo instances or development platforms
we are not supporting a wide range of platforms.
CentOS release 6.8 (Final) is supported currently.

Usage

For demo instance default recipe should be used.
For development purpose use aet::_develop and aet::default recipes.
The aet::_develop recipe provides additional user used by Maven to upload AET artifacts.

Preparing virtual machine

Include aet in your node's run_list:

{
  "run_list": [
    "recipe[aet::_develop]",
    "recipe[aet::default]"
  ]
}

Using AET

After you have AET instance up and running you could prepare a Maven project to run AET tests.
Please refer to the AET documentation on how to setup a test suite.

AET Components

The cookbook installs following components required by AET:

Those components may be installed on separate machines
provided they have been configured to work with each other.
The configuration is done within Karaf Web Console.

Validation of AET components

  • Karaf - Karaf Web Console should be available at http://192.168.123.100:8181/system/console/bundles. Default credentials: karaf/karaf.
  • Active MQ - Active MQ Web Console should be available at http://192.168.123.100:8161 Default credentials: admin/admin.
  • Mongo DB - curl -I 192.168.123.100:27017 responding with Empty response means that Mongo is listening on default port.
  • Apache HTTP Server - could be checked with curl -I 192.168.123.100
  • Tomcat - could be checked with curl -I 192.168.123.100:9090
  • Selenium Grid - Selenium Grid Hub should be available at http://192.168.123.100:4444/grid/console. Selenium Grid nodes should be listed there as well.
  • Browsermob - try curl -I 192.168.123.100:8080. Expected response is:
HTTP/1.1 404 Not Found
Cache-Control: must-revalidate,no-cache,no-store
Content-Type: text/html;charset=ISO-8859-1
Content-Length: 1267
Server: Jetty(7.3.0.v20110203)

Recipes

Recipes below are presented in groups.
Each group (except common) should be installed on same system.

Common

  • java::default - Installs Open JDK 8 required by other AET components. Uses JAVA cookbook, so the JAVA version might be changed with that cookbook properties.

Active MQ

Recipes:

  • aet::activemq - creates dedicated user (configured with node['aet']['activemq']['user'] and node['aet']['activemq']['group']), downloads and install binary distribution of Active MQ (using binary package from node['aet']['activemq']['source']). Registers Active MQ as a service (/etc/init.d/activemq).

Apache and AET report web application

Recipes:

  • aet::apache - Uses Apache cookbook. Installs Apache HTTP server. Additionally creates a folder (node['aet']['apache']['log_dir']) for apache logs and creates a link from /var/log/httpd to that folder. Enables proxy, proxy_http and headers modules. If aet::_develop recipe is used, then apache service is run with develop system user.
  • aet::deploy_reports - checks if node['aet']['version'] is currently linked as current folder. If no then downloads that version of AET reports web application and extract it into node['aet']['apache']['report_base_dir']/aet_reports/#{ver}. Creates a link from node['aet']['apache']['report_base_dir']/aet_reports/current to the version folder. Setup virtual host for serving a content from the current folder. If aet::_develop recipe is used this is done with develop user.

Karaf, Browsermob, XVFB and Firefox

Recipes:

  • aet::karaf - Creates dedicated system user for Karaf service. If aet::_develop recipe is used, then this user is overwritten by develop user. Downloads Karaf and extracts it into node['aet']['karaf']['root_dir']. Creates a symbolic link from node['aet']['karaf']['root_dir']/current to extracted Karaf instance. Sets the Web Console credentials in users.properties file and HTTP port in org.ops4j.pax.web.cfg file). Creates symbolic link from Karaf log dir to node['aet']['karaf']['log_dir']. Registers Karaf as a service (/etc/init.d/karaf) and starts it.
  • aet::deploy_aet_for_karaf - Deploys AET artifacts for Karaf. This is done only for new installation or when version is changed for AET. New artifacts are downloaded and extracted. Then link with the name of 'current' is created that points to the new version folder. Then Karaf restart is scheduled. If aet::_develop recipe is used this is done with develop user.
  • aet::postdeploy_restart - Check if karaf restart was scheduled (if /tmp/karaf-restart file exists). If so, then stops Karaf service, deletes Karaf cache folders and starts Karaf again.
  • aet::browsermob - Creates dedicated user for Browsermob service. Installs Browsermob into node['aet']['browsermob']['root_dir']. Registers it as a service (/etc/init.d/browsermob) and starts it.
  • aet::firefox - Creates dedicated user for firefox folders permissions. Downloads (from node['aet']['firefox']['source']) and installs Firefox browser. Configures Firefox to use virtual display from XVFB.
  • aet::xvfb - Creates dedicated user for xvfb. Installs XVFB service and configures it to use node['aet']['xvfb']['log_dir'] as log dir. The resolution for virtual screen may be set by node['aet']['xvfb']['resolution']. The default value is '1280x1024x24'.

Tomcat and Sample Site

Recipes:

  • aet::tomcat - Creates dedicated user for Tomcat service. If aet::_develop recipe is used, then this user is overwritten by develop user. Downloads tomcat and installs it into node['aet']['tomcat']['base_dir']. Configures JAVA settings, tomcat port and tomcat users. Registers tomcat as a service (/etc/init.d/tomcat) and enables it.
  • aet::deploy_sample_site - Checks if node['aet']['karaf']['root_dir']/tomcat/aet_sample_site/current is a link to current version (node['aet']['version']) of sample site. If not, then downloads required version, extracts it to node['aet']['karaf']['root_dir']/tomcat/aet_sample_site/#{ver}, creates a link from current to this version and restarts tomcat. If aet::_develop recipe is used this is done with develop user.

Selenium Grid hub

  • aet::seleniumgrid_hub - Creates dedicated user for Selenium Grid service. If aet::_develop recipe is used, then this user is overwritten by develop user. Downloads selenium standalone server and installs hub into node['aet']['selenium']['hub']['root_dir']. Registers seleniumgrid-hub as a service (/etc/init.d/hub), enables and starts it.

Selenium Grid Firefox node

  • aet::seleniumgrid_node_ff - Creates dedicated user for Selenium Grid service. If aet::_develop recipe is used, then this user is overwritten by develop user. Downloads selenium standalone server and installs Selenium node in node['aet']['selenium']['node_ff']['root_dir']. Uses existing Firefox browser /usr/bin/firefox without gecko driver ("marionette" set to false). Registers node-ff as a service (/etc/init.d/node-ff), enables and starts it.

_develop recipe

  • aet::_develop - Please note that this recipe is not included by default. If included it will override system users for Tomcat, Karaf and Apache with develop user. This has been done in order to enable uploads of AET artifacts to these services.

Mongo DB

Recipes:

X Window

Recipes:

  • aet::display - Installs X Window for the convenience of virtual machine users.
  • aet::reboot - After X Window is installed the system needs one reboot. This cookbook schedules reboot of virtual machine. The reboot is done only once.

Attributes

See attributes/ folder for default values.

  • node['aet']['version'] - version of AET to set-up. Used by deploy recipes. (default: '3.0.0')
  • node['aet']['base_link'] - base link for AET release artifacts. (default: 'https://github.com/Cognifide/AET/releases/download')
  • node['aet']['activemq']['root_dir'] - parent folder for Active MQ installation (default: '/opt/aet/activemq')
  • node['aet']['activemq']['log_dir'] - log dir for Active MQ (default: '/var/log/activemq')
  • node['aet']['activemq']['user'] - system user for Active MQ service (default: 'activemq')
  • node['aet']['activemq']['group'] - system group for Active MQ service (default: 'activemq')
  • node['aet']['activemq']['login'] - login for Active MQ Web Console (default: 'admin')
  • node['aet']['activemq']['password'] - password for Active MQ Web Console (default: 'admin')
  • node['aet']['activemq']['java_min_mem'] - min heap for Active MQ (default: '64M')
  • node['aet']['activemq']['java_max_mem'] - max heap for Active MQ (default: '1024M')
  • node['aet']['activemq']['java_min_perm_mem'] - min permanent space for Active MQ (default: '64M')
  • node['aet']['activemq']['java_max_perm_mem'] - max permanent space for Active MQ (default: '128M')
  • node['aet']['activemq']['jmx_port'] - port to use by Active MQ (default: '11199')
  • node['aet']['activemq']['jmx_ip'] - IP for Active MQ JMX (default: node['ipaddress'])
  • node['aet']['activemq']['enable_debug'] - enables JAVA debug agent on port 5006 (default: false)
  • node['aet']['activemq']['src_cookbook']['env'] - source cookbook for file template of env (default: 'aet')
  • node['aet']['activemq']['src_cookbook']['activemq_xml'] - source cookbook for file template of activemq.xml (default: 'aet')
  • node['aet']['activemq']['src_cookbook']['jetty_prop'] - source cookbook for file template of jetty-realm.properties (default: 'aet')
  • node['aet']['activemq']['src_cookbook']['log4j_prop'] - source cookbook for file template of log4j.properties (default: 'aet')
  • node['aet']['apache']['report_base_dir'] - folder for AET reports web application (default: '/opt/aet/apache')
  • node['aet']['apache']['log_dir'] - apache logs folder (will be linked from /var/log/httpd) (default: '/var/log/apache')
  • node['aet']['apache']['karaf_ip'] - Karaf IP that the requests will be proxied to (default: 'localhost')
  • node['aet']['apache']['src_cookbook']['reports_conf'] - source cookbook for file template of reports vhost (default: 'aet')
  • node['aet']['browsermob']['source'] - URL for browsermob proxy ZIP archive
  • node['aet']['browsermob']['root_dir'] - parent folder for Browsermob installation (default: 'aet')
  • node['aet']['browsermob']['log_dir'] - Browsermob logs folder (default: '/var/log/browsermob')
  • node['aet']['browsermob']['user'] - system user for Browsermob service (default: 'browsermob')
  • node['aet']['browsermob']['group'] - system group for Browsermob service (default: 'browsermob')
  • node['aet']['browsermob']['port'] - port for Browsermob proxy (default: '8080')
  • node['aet']['browsermob']['src_cookbook']['init_script'] - source cookbook for file template of browsermob init script (default: 'aet')
  • node['aet']['firefox']['root_dir'] - parent folder for Firefox browser installation (default: '/opt/aet/firefox')
  • node['aet']['firefox']['log_dir'] - Firefox log folder path (default: '/opt/aet/firefox/log')
  • node['aet']['firefox']['src_cookbook']['bin'] - source cookbook for file template of firefox start script (default: 'aet')
  • node['aet']['karaf']['source'] - source URL for Karaf download (default: 'https://archive.apache.org/dist/karaf/4.2.0/apache-karaf-4.2.0.tar.gz')
  • node['aet']['karaf']['user'] - system user for Karaf service (default: 'karaf')
  • node['aet']['karaf']['group'] - system group for Karaf service (default: 'karaf')
  • node['aet']['karaf']['login'] - login for Karaf instance (WebConsole, SSH) (default: 'karaf')
  • node['aet']['karaf']['password'] - password for Karaf instance (WebConsole, SSH) (default: 'karaf')
  • node['aet']['karaf']['root_dir'] - parent folder for Karaf installation (default: '/opt/aet/karaf')
  • node['aet']['karaf']['log_dir'] - log dir for Karaf (default: '/var/log/karaf')
  • node['aet']['karaf']['enable_debug'] - enables JAVA debug agent on port 5005 (default: false)
  • node['aet']['karaf']['web_port'] - HTTP port for Karaf (default: '8181')
  • node['aet']['karaf']['ssh_port'] - SSH port for Karaf (default: '8101')
  • node['aet']['karaf']['java_min_mem'] - min heap for Karaf (default: '512M')
  • node['aet']['karaf']['java_max_mem'] - max heap for Karaf (default: '1024M')
  • node['aet']['karaf']['java_min_perm_mem'] - min permanent space for Karaf (default: '64M')
  • node['aet']['karaf']['java_max_perm_mem'] - max permanent space for Karaf (default: '128M')
  • node['aet']['karaf']['src_cookbook']['setenv'] - source cookbook for file template of setenv.sh (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['users_prop'] - source cookbook for file template of users.properties (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['fileinstall_configs_prop'] - source cookbook for file template of org.apache.felix.fileinstall-aet_configs.cfg (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['fileinstall_features_prop'] - source cookbook for file template of org.apache.felix.fileinstall-aet_features.cfg (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['fileinstall_bundles_prop'] - source cookbook for file template of org.apache.felix.fileinstall-aet_bundles.cfg (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['shell_cfg'] - source cookbook for file template of org.apache.karaf.shell.cfg (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['ops4j_cfg'] - source cookbook for file template of org.ops4j.pax.web.cfg (default: 'aet')
  • node['aet']['karaf']['src_cookbook']['init_script'] - source cookbook for file template of karaf init script (default: 'aet')
  • node['aet']['tomcat']['base_dir'] - parent folder for Tomcat installation (default: '/opt/aet/tomcat')
  • node['aet']['tomcat']['log_dir'] - log dir for Tomcat (default: '/var/log/tomcat')
  • node['aet']['tomcat']['user'] - system user for Tomcat service (default: 'tomcat')
  • node['aet']['tomcat']['group'] - system group for Tomcat service (default: 'tomcat')
  • node['aet']['tomcat']['debug_enabled'] - enables JAVA debug agent on port (default: false)
  • node['aet']['tomcat']['debug_port'] - default value is '29090'
  • node['aet']['tomcat']['jmx_enabled'] - enables JMX for Tomcat (default: true)
  • node['aet']['tomcat']['jmx_port'] - default value is '19090'
  • node['aet']['tomcat']['port'] - default value is '9090' (as 8080 is used by Browsermob)
  • node['aet']['tomcat']['min_heap'] - min heap for Tomcat (default: '256')
  • node['aet']['tomcat']['max_heap'] - max heap for Tomcat (default: '512')
  • node['aet']['tomcat']['max_permsize'] - max permanent space for Tomcat (default: '256')
  • node['aet']['tomcat']['connector']['maxswallowsize'] - for Tomcat maxSwallowSize (default: '2097152')
  • node['aet']['tomcat']['login'] - login for Tomcat instance (i.e. Manager app) (default: 'admin')
  • node['aet']['tomcat']['password'] - password for Tomcat instance (i.e. Manager app) (default: 'admin')
  • node['aet']['tomcat']['src_cookbook']['setenv'] - source cookbook for file template of setenv.sh (default: 'aet')
  • node['aet']['tomcat']['src_cookbook']['server_xml'] - source cookbook for file template of server.xml (default: 'aet')
  • node['aet']['tomcat']['src_cookbook']['users_xml'] - source cookbook for file template of tomcat-users.xml (default: 'aet')
  • node['aet']['tomcat']['src_cookbook']['init_script'] - source cookbook for file template of tomcat init script (default: 'aet')
  • node['aet']['seleniumgrid']['user'] - system user for Selenium Grid service (default: 'seleniumgrid')
  • node['aet']['seleniumgrid']['group'] - system group for Selenium Grid service (default: 'seleniumgrid)
  • node['aet']['seleniumgrid']['source'] - URL for Selenium Grid standalone server jar
  • node['aet']['seleniumgrid']['hub']['root_dir'] - parent folder for Selenium Grid hub installation (default: '/opt/aet/seleniumgrid/hub')
  • node['aet']['seleniumgrid']['hub']['log_dir'] - Selenium Grid hub logs folder (default: '/var/log/seleniumgrid')
  • node['aet']['seleniumgrid']['hub']['src_cookbook']['init_script'] - source cookbook for file template of Selenium Grid hub init script (default: 'aet')
  • node['aet']['seleniumgrid']['node_ff']['root_dir'] - parent folder for Selenium Grid firefox node installation (default: '/opt/aet/seleniumgrid/node-ff')
  • node['aet']['seleniumgrid']['node_ff']['log_dir'] - Selenium Grid firefox node logs folder (default: '/var/log/seleniumgrid')
  • node['aet']['seleniumgrid']['node_ff']['src_cookbook']['init_script'] - source cookbook for file template of Selenium Grid Firefox node init script (default: 'aet')
  • node['aet']['xvfb']['user'] - system user for XVFB (default: 'xvfb')
  • node['aet']['xvfb']['group'] - system group for XVFB (default: 'xvfb')
  • node['aet']['xvfb']['log_dir'] - log dir for XVFB (default: '/var/log/xvfb')
  • node['aet']['xvfb']['src_cookbook']['init_script'] - source cookbook for file template of xvfb init script (default: 'aet')
  • node['aet']['develop']['user'] - user for develop instance
  • node['aet']['develop']['group'] - group for develop instance
  • node['aet']['develop']['ssh_password'] - hashed password for develop user (generated with openssl passwd -1 "password")

Hashed passwords

In order to generate hashed password for an user please use following command:

[vagrant@aet-vagrant ~]$ openssl passwd -1 "password"
$1$WxkKLOya$9ZOsQs7YdfjZB1wsaJPkW0
[vagrant@aet-vagrant ~]$

Automated tests with Kitchen

kitchen list command shows list of available suites. Sample test execution might look like this:

berks update
kitchen verify karaf-centos-68

To run all existing tests you cun use this command:

berks update
kitchen test --concurrency 4 --parallel

New version release

Deployment of new versions of this cookbook is managed with Stove.
For Ruby on windows you can use Ruby Installer.
Chef Supermarket login and key is required for new version deployment.

New version needs to be numeric in form of X.Y or X.Y.Z.

Prepare Stove

Inside the aet-cookbook install bundler:

gem install bundle

Then install gems required by stove (which is already added to Gemfile):

bundle install

Configure your Chef credentials (see stove configuration)

Create new version

  1. Update metadata.rb file to contain the version that should be released (Cookbook Versioning Policy).
  2. Update CHANGELOG.md file: provide version number for unreleased changes.
  3. Commit and push changes. Create a GIT tag with version number i.e. v3.1.0.

Deploy Cookbook

To send the current version of cookbook to Chef supermarket run

stove --no-git --username  --key 

Update to next version

After cookbook deployment update metadata.rb and CHANGELOG.md files for new development lifecycle.

License and Authors

Authors:

License: Apache License, Version 2.0

Dependent cookbooks

apache2 ~> 5.0.1
java ~> 2.2.0
sc-mongodb ~> 1.2.0

Contingent cookbooks

There are no cookbooks that are contingent upon this one.

Unreleased

  • ..

5.1.3

  • PR-46 Bumping apache cookbook version from 3.3.1 to 5.0.1
  • PR-44 Added mode rewrite module to apache - required for AET #152

5.1.2

  • AET release of 3.2.2 version

5.1.1

Important: if you're upgrading from aet-cookbook versions v5.0.0 or v5.1.0 please follow the instructions in the PR-43 description

5.1.0

Important due to #42 issue, if you are upgrading from earlier cookbook version, please use 5.1.1 instead.
* Configurable Browsermob proxy port range

5.0.0

Important due to #42 issue, if you are upgrading from earlier cookbook version, please use 5.1.1 instead.

  • AET release of version 3.0.0
  • Apache config (vhost) to proxy Web API requests to Karaf port
  • Selenium grid hub upgrade from 3.8.1 to 3.14.0
  • Dependant cookbooks upgrade and change for Mongo DB cookbook

4.0.1

  • Fix for missing attributes, README updated

4.0.0

  • Karaf upgrade to version 4.2.0
  • Karaf upgrade to version 4.1.5
  • Fix for Karaf cache clearing

3.0.0

  • Fix for Karaf service script
  • Selenium Grid recipes added for hub and node with Firefox 38.6
  • Gzip compression added for Apache (Report application)

2.0.1

  • Attribute for Firefox log folder introduced

2.0.0

  • Changes for cookbook to run AET with JAVA 8
  • Karaf upgrade to version 4.1.4
  • ActiveMQ version upgrade to 5.15.2
  • Folders for AET artifacts reorganized
  • Not needed Karaf templates removed
  • One recipe instead of three for AET artifacts: deploy_aet_for_karaf
  • README updated

1.4.15

  • Switch to OpenJDK, as JAVA 7 is unable to be automatically downloaded by Java Cookbook.

1.4.14

  • Karaf IP configurable in vhost template

1.4.13

  • Update Browsermob version to 2.1.4
  • Fix for developer user homedir creation
  • Default AET deployment version changed to 2.0.2
  • Adding source cookbooks for all templates
  • Fixing missing homedirs for services

1.4.12

  • Fix for deploy_reports recipe
  • Spare attribute removed from .kitchen.yml file

1.4.11

  • Fixes and improvements before going open source

1.4.10

  • aet::_develop made private recipe

1.4.9

  • default URL for Tomcat download changed

1.4.8

  • new user added for deploying AET artifacts within build lifecycle
  • folders paths for AET artifacts moved out of current Karaf instance
  • deploy_configs recipe renamed
  • removed code for checking if deploy to Karaf is required

1.4.7

  • Adding CORS to /api proxy in aet vhost

1.4.6

  • Fixing issues with reports

1.4.5

  • AET release of 1.4.3 version

1.4.4

  • Fixing browsermob init script

1.4.3

  • Switching links to public ones
  • Splitting Karaf deploy to three independent recipes
  • Using supermarket version of maven recipe
  • Adding Apache to handle reporting
  • Adding report deployment
  • Adding Tomcat and package deployment
  • Removing Jetty from cookbook

1.4.0

  • Support for Jetty on Vagrant added (sample app for sanity tests)

0.1.0

  • Initial release of aet

Collaborator Number Metric
            

5.1.3 passed this metric

Contributing File Metric
            

5.1.3 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a CONTRIBUTING.md file

Foodcritic Metric
            

5.1.3 failed this metric

FC066: Ensure chef_version is set in metadata: aet/metadata.rb:1
FC069: Ensure standardized license defined in metadata: aet/metadata.rb:1
FC070: Ensure supports metadata defines valid platforms: aet/metadata.rb:1
Run with Foodcritic Version 16.3.0 with tags metadata,correctness ~FC031 ~FC045 and failure tags any

No Binaries Metric
            

5.1.3 passed this metric

Testing File Metric
            

5.1.3 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must contain a TESTING.md file

Version Tag Metric
            

5.1.3 failed this metric

Failure: To pass this metric, your cookbook metadata must include a source url, the source url must be in the form of https://github.com/user/repo, and your repo must include a tag that matches this cookbook version number