docker-selenium icon indicating copy to clipboard operation
docker-selenium copied to clipboard

Selenium Fail in Openshift

Open jared-ziqxu opened this issue 9 years ago • 0 comments

Meta -

Image(s): Selenium 3.4.0 hub Docker-Selenium Image Version(s): 3.4.0

Openshift Version: 3.7.0

Expected Behavior -

Selenium hub launch correctly, and load the paramaters(browserTimeout etc.) configured in env correctly.

Actual Behavior -

Selenium hub keeps reporting the following error, while the customized parameters(browserTimeout etc.) are not taking effect.

starting selenium hub with configuration: /opt/bin/entry_point.sh: line 6: /opt/selenium/config.json: Permission denied { "host": null, "port": 4444, "role": "hub", "maxSession": 5, "newSessionWaitTimeout": -1, "capabilityMatcher": "org.openqa.grid.internal.utils.DefaultCapabilityMatcher", "throwOnCapabilityNotPresent": true, "jettyMaxThreads": -1, "cleanUpCycle": 5000, "browserTimeout": 0, "timeout": 30, "debug": false } 15:59:13.553 INFO - Selenium build info: version: '3.4.0', revision: 'unknown' 15:59:13.554 INFO - Launching Selenium Grid hub

Template that I use

apiVersion: v1
kind: Template
metadata:
  name: selenium-hub 
objects:
- apiVersion: v1
  kind: Route
  metadata:
    name: ${SELENIUM_HUB_NAME}-route
  spec:
    host: ${SELENIUM_HUB_NAME}.openshift.url.com
    to:
      kind: Service
      name: ${SELENIUM_HUB_NAME}-service
    port:
      targetPort: web
- apiVersion: v1
  kind: DeploymentConfig
  metadata: 
    name: ${SELENIUM_HUB_NAME}
  spec:
     replica: 1
     strategy:
       type: Recreate
     triggers:
       - type: ConfigChange
     template:
       metadata:
         name: ${SELENIUM_HUB_NAME} 
         labels:
           service: ${SELENIUM_HUB_NAME}
       spec:
         restartPolicy: Always
         containers:
         - image: selenium/hub:${SELENIUM_VERSION}
           name: ${SELENIUM_HUB_NAME}
           env:
           - name: JAVA_OPTS
             value: -Xmx512m
           - name: POOL_MAX
             value: "30000"
           - name: GRID_NEW_SESSION_WAIT_TIMEOUT
             value: "30"
           - name: GRID_JETTY_MAX_THREADS
             value: "100"
           - name: GRID_NODE_POLLING
             value: "150"
           - name: GRID_CLEAN_UP_CYCLE
             value: "300"
           - name: GRID_TIMEOUT
             value: "300"
           - name: GRID_BROWSER_TIMEOUT
             value: "60"
           - name: GRID_MAX_SESSION
             value: "4"
           - name: GRID_UNREGISTER_IF_STILL_DOWN_AFTER
             value: "500"
           ports:
           - containerPort: 4444
             protocol: TCP
           livenessProbe:
             failureThreshold: 3
             httpGet:
               path: /
               port: 4444
               scheme: HTTP
             periodSeconds: 10
             successThreshold: 1
             timeoutSeconds: 5
             initialDelaySeconds: 15
           readinessProbe:
             failureThreshold: 3
             httpGet:
               path: /
               port: 4444
               scheme: HTTP
             periodSeconds: 10
             successThreshold: 1
             timeoutSeconds: 5
             initialDelaySeconds: 15
- apiVersion: v1
  kind: Service
  metadata:
    labels:
      service: ${SELENIUM_HUB_NAME}
    name: ${SELENIUM_HUB_NAME}-service
  spec:
    selector:
      service: ${SELENIUM_HUB_NAME}
    type: ClusterIP
    ports:
    - name: web
      port: 4444
      targetPort: 4444
      protocol: TCP
    - name: node
      port: 5555
      targetPort: 5555
      protocol: TCP
parameters:
- description: Specific name of the Selenium hub application
  displayName: Selenium Hub Service Name
  name: SELENIUM_HUB_NAME
  value: selenium-hub-sandbox
  required: true
- description: Version of Selenium Hub
  displayName: Version of Selenium Hub
  name: SELENIUM_VERSION
  value: 3.4.0
  required: true

jared-ziqxu avatar Nov 20 '17 17:11 jared-ziqxu