- add npm workflow to fetch recent Jira issues, summarize them, and create a target Jira ticket - generate HTML report and optional SMTP email output - add Docker runtime and TeamCity runner scripts (sh/ps1) - support optional SOLUTION_VERSION, XRAY_REPORT_URL, SONAR_REPORT_URL - map SOLUTION_VERSION to Jira fixVersions on ticket creation - update README and .env.example with new configuration
38 lines
859 B
Bash
38 lines
859 B
Bash
#!/usr/bin/env sh
|
|
set -eu
|
|
|
|
IMAGE_TAG="${TEAMCITY_BUILD_NUMBER:-local}"
|
|
IMAGE_NAME="its-workflow-npm:${IMAGE_TAG}"
|
|
|
|
echo "Builde Docker Image ${IMAGE_NAME}"
|
|
docker build -t "${IMAGE_NAME}" .
|
|
|
|
echo "Starte Workflow Container"
|
|
docker run --rm \
|
|
-e JIRA_BASE_URL \
|
|
-e JIRA_USER_EMAIL \
|
|
-e JIRA_API_TOKEN \
|
|
-e JIRA_SOURCE_JQL \
|
|
-e JIRA_SOURCE_MAX_RESULTS \
|
|
-e JIRA_TARGET_PROJECT_KEY \
|
|
-e JIRA_TARGET_BOARD_ID \
|
|
-e JIRA_TARGET_ISSUE_TYPE \
|
|
-e JIRA_TARGET_SUMMARY_PREFIX \
|
|
-e JIRA_TARGET_LABELS \
|
|
-e SOLUTION_VERSION \
|
|
-e XRAY_REPORT_URL \
|
|
-e SONAR_REPORT_URL \
|
|
-e JIRA_DRY_RUN \
|
|
-e OUTPUT_HTML_PATH \
|
|
-e SMTP_ENABLED \
|
|
-e SMTP_HOST \
|
|
-e SMTP_PORT \
|
|
-e SMTP_SECURE \
|
|
-e SMTP_USER \
|
|
-e SMTP_PASS \
|
|
-e SMTP_FROM \
|
|
-e SMTP_TO \
|
|
-e SMTP_SUBJECT_PREFIX \
|
|
-v "$(pwd)/report-output:/app/report-output" \
|
|
"${IMAGE_NAME}"
|