Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Webhook Service Deployment (Jar): -

  • Create a directory under folder opt “zephyrservice”

Code Block
mkdir zephyrservice
  • Download the ze-jira-webhook.jar and copy it under zephyrservice

  • Create a ze-jira-webhook config file Named “zeJiraWebhook.properties" under folder zephyrservice

Code Block
vi zeJiraWebhook.properties
  • Add the below line in the file zeJiraWebhook.properties.

Code Block
#Webhook Service port
server.port

...

=8081

#context path property
server.servlet.context-path=/webhook

#Rabbitmq config
zephyr.queue.name=ze_queue
zephyr.queue.exchange=ze_exchange
zephyr.queue.routing.key=ze_routing_key

spring.rabbitmq.host=<hostname>
spring.rabbitmq.port=<port>
spring.rabbitmq.username=<username>
spring.rabbitmq.password=<password>

#ze_jira_webhook flags
event.validator.json.file=classpath:webhook-events-validation.json
ze.jira.webhook.event.validation_flag = false

...

Append below lines for ssl

...



#ssl properties

...

 
#uncomment the below line and add the SSL 
#server.ssl.enabled=true

...

#server.ssl.key-store-type=PKCS12

...

#server.ssl.key-alias=<aliasname>

...

#server.ssl.key-store=file:<path of the certificate>

...

#server.ssl.key-store-password=<password>

...

Append below lines for context path

...

  • An example of zeJiraWebhook.properties should look like the below: -

    View file
    namezeJiraWebhook (1).properties

Code Block
#Webhook Service port
server.port=4438081

#context path property
server.servlet.context-path=/ze-webhook

#Rabbitmq config
zephyr.queue.name=ze_queue
zephyr.queue.exchange=ze_exchange
zephyr.queue.routing.key=ze_routing_key
spring.rabbitmq.host=localhost
spring.rabbitmq.port=5672
spring.rabbitmq.username=guest
spring.rabbitmq.password=guest

# ze_jira_webhook flags
event.validator.json.file=classpath:webhook-events-validation.json
ze.jira.webhook.event.validation_flag = false

#ssl properties
server.ssl.enabled=true
server.ssl.key-store-type=PKCS12
server.ssl.key-alias=mycert
server.ssl.key-store=file:/home/ubuntu/keystore.p12
server.ssl.key-store-password=changeit
Info
  • Make sure port 8081 is available.

  • zeJiraWebhook should be able to connect with RabbitMQ.

  • Open the “Terminal” or “Command Prompt”

  • Navigate to folder /opt/zephyrservice

  • Type the below command

Start the ze-jira-webhook with the following command.

Code Block
sudo nohup java -jar -DzeWebhookConfigPath="<config file path till root folder>" ze-jira-webhook_<version>.jar &

Example command:

Code Block
sudo nohup java -jar -DzeWebhookConfigPath="/home/ubuntuopt/Foldernamezephyrservice" ze-jira-webhook.jar &

Log

  • The Logs folder will be created where your jars are deployed. Separate log files will be created for each jar. In the above example, it will be in /opt/zephyrservice.

Verification

Verify webhook application status by using http://<hostname>:8080/actuator/health

Webhook started snapshot for reference: -

...

Verification in the browser:

...

Webhook Service Deployment (Docker): -

  • Install Docker in the System

  • Create a directory under folder opt “zephyrservice”

Code Block
mkdir zephyrservice
  • Download the Docker compose and copy it under zephyrservice

    View file
    namedocker-compose.yaml

Code Block
#dockercompose

version: '3.5'
services:

  #webhookservice
  ze-jira-webhook:
    image: zephyrdevbot/zedevservices:ze-jira-webhook
    container_name: ze-jira-webhook
    ports:
      - "8081:8081"
      - "8000:8000"
    environment:
      - server_port=8081
    volumes:
      - ./zeJiraWebhook.properties:/usr/src/app/zeJiraWebhook.properties
    networks:
      - webhook_service

networks:
  webhook_service:
    name: zephyr
    external: true
  • Create a ze-jira-webhook config file Named “zeJiraWebhook.properties" under folder zephyrservice

Code Block
vi zeJiraWebhook.properties
  • Add the below line in the file zeJiraWebhook.properties.

Code Block
#Webhook Service port
server.port=8081

#context path property
server.servlet.context-path=/webhook

#Rabbitmq config
zephyr.queue.name=ze_queue
zephyr.queue.exchange=ze_exchange
zephyr.queue.routing.key=ze_routing_key

spring.rabbitmq.host=<hostname>
spring.rabbitmq.port=<port>
spring.rabbitmq.username=<username>
spring.rabbitmq.password=<password>

#ze_jira_webhook flags
event.validator.json.file=classpath:webhook-events-validation.json
ze.jira.webhook.event.validation_flag = false

#ssl properties 
#uncomment the below line and add the SSL 
#server.ssl.enabled=true
#server.ssl.key-store-type=PKCS12
#server.ssl.key-alias=<aliasname>
#server.ssl.key-store=file:<path of the certificate>
#server.ssl.key-store-password=<password>
  • An example of zeJiraWebhook.properties should look like the below: -

    View file
    namezeJiraWebhook (2).properties

Code Block
#Webhook Service port
server.port=8081

#context path property
server.servlet.context-path=/webhook

#Rabbitmq config
zephyr.queue.name=ze_queue
zephyr.queue.exchange=ze_exchange
zephyr.queue.routing.key=ze_routing_key
spring.rabbitmq.host=localhost
spring.rabbitmq.port=5672
spring.rabbitmq.username=guest
spring.rabbitmq.password=guest

# ze_jira_webhook flags
event.validator.json.file=classpath:webhook-events-validation.json
ze.jira.webhook.event.validation_flag = false

#ssl properties
server.ssl.enabled=true
server.ssl.key-store-type=PKCS12
server.ssl.key-alias=mycert
server.ssl.key-store=file:/home/ubuntu/keystore.p12
server.ssl.key-store-password=changeit
Info
  • Make sure port 8081 is available.

  • zeJiraWebhook should able to connect with RabbitMQ.

Start the ze-jira-webhook with docker with the following command

  • Navigate to zephyrservice and run the below command.

Code Block
docker-compose up -d 

Verification

Webhook started snapshot for reference: -

...

Verification in the browser:

Verify webhook application status by using http://<hostname>:8081/webhook/actuator/health

...