Ciinabox2 0.4.0

Updates

External Services

External services allow other build and testing tools to run on the ciinabox ECS infrastructure such as Selenium, GitLab server or Artifactory. These services are designed to be run all the time and be reached through the ciinabox load balancer. Some default external services will exists in the ciinabox tool and with release Selenium will be available with more to follow.

Custom services can also be added though the ciinabox config by using the following config syntax with the ecs-service highlander component config syntax under the service: key.

ciinabox_services:
  myservice:
    enable: true
    fargate: true
    desired_count: 1
    versions: 
      myservice: 3
    service:
      ... # highlander ecs-service config

Selenium

The Selenium ciinabox service is run on Fargate and uses the Selenium hub configuration attaching Chrome and Firefox nodes. All 3 containers are run in the same task definition and can be accessed through the ciinabox loadbalancer or through service discovery both using the selenium host record.

Selenium is enabled through the ciinabox config. The following example enabled selenium with the default configuration defined by ciinabox.

ciinabox_services:
  selenium:
    enable: true

The selenimun docker tag can be overriden

ciinabox_services:
  selenium:
    enable: true
    versions:
      selenium: 4.0.0

Service and task definitions can also be overriden using the config from the ecs-services highlander component. For example if we wanted to add the Opera node to the Selenium hub we add anther task to the task definition supplying the image, tag_param of SeleniumVersion and the required environment variables.

ciinabox_services:
  selenium:
    enable: true
    service:
      task_definition:
        opera:
          image: selenium/node-opera
          tag_param: SeleniumVersion
          env_vars:
            HUB_HOST: localhost
            HUB_PORT: 4444
            START_XVFB: false
            SE_OPTS: -port 5557

Noting the SE_OPTS: -port 5557 configuration, because it’s using awsvpc networking and all tasks are in the same task definition it uses local networking meaning all Selenium nodes will need to be run on different ports. Chrome is using port 5555 and Firefox is using port 5556.