Skip to content

Conversation

@sghosh23
Copy link

Features:

  • Dropdown with versions 5.24.0 to 5.5.0
  • Pin wire-server and all charts at same version
  • Automatically finds and updates matching chart versions
  • Creates PR to wire-server-deploy with detailed changelog

Usage:

  1. Manually trigger workflow
  2. Select version from dropdown (default: none)
  3. Workflow pins all charts with current wire-server version to selected version
  4. Creates/updates PR in wire-server-deploy

PR Submission Checklist for internal contributors

  • The PR Title

    • conforms to the style of semantic commits messages¹ supported in Wire's Github Workflow²
    • contains a reference JIRA issue number like SQPIT-764
    • answers the question: If merged, this PR will: ... ³
  • The PR Description

    • is free of optional paragraphs and you have filled the relevant parts to the best of your ability

What's new in this PR?

Issues

Briefly describe the issue you have solved or implemented with this pull request. If the PR contains multiple issues, use a bullet list.

Causes (Optional)

Briefly describe the causes behind the issues. This could be helpful to understand the adopted solutions behind some nasty bugs or complex issues.

Solutions

Briefly describe the solutions you have implemented for the issues explained above.

Dependencies (Optional)

If there are some other pull requests related to this one (e.g. new releases of frameworks), specify them here.

Needs releases with:

  • GitHub link to other pull request

Testing

Test Coverage (Optional)

  • I have added automated test to this contribution

How to Test

Briefly describe how this change was tested and if applicable the exact steps taken to verify that it works as expected.

Notes (Optional)

Specify here any other facts that you think are important for this issue.

Attachments (Optional)

Attachments like images, videos, etc. (drag and drop in the text box)


PR Post Submission Checklist for internal contributors (Optional)

  • Wire's Github Workflow has automatically linked the PR to a JIRA issue

PR Post Merge Checklist for internal contributors

  • If any soft of configuration variable was introduced by this PR, it has been added to the relevant documents and the CI jobs have been updated.

References
  1. https://sparkbox.com/foundry/semantic_commit_messages
  2. https://github.com/wireapp/.github#usage
  3. E.g. feat(conversation-list): Sort conversations by most emojis in the title #SQPIT-764.

sghosh23 and others added 9 commits December 17, 2025 16:01
Features:
- Dropdown with versions 5.24.0 to 5.5.0
- Pin wire-server and all charts at same version
- Automatically finds and updates matching chart versions
- Creates PR to wire-server-deploy with detailed changelog

Usage:
1. Manually trigger workflow
2. Select version from dropdown (default: none)
3. Workflow pins all charts with current wire-server version to selected version
4. Creates/updates PR in wire-server-deploy
- Add git push after version pinning commit
- Change permissions from read to write for contents
- Ensures commit SHA exists on GitHub before curl tries to fetch it
Charts updated from 5.24.0 to 5.23.0:
wire-server redis-ephemeral rabbitmq rabbitmq-external databases-ephemeral fake-aws fake-aws-s3 fake-aws-sqs aws-ingress fluent-bit kibana backoffice calling-test demo-smtp elasticsearch-curator elasticsearch-external elasticsearch-ephemeral minio-external cassandra-external ingress-nginx-controller nginx-ingress-services reaper restund k8ssandra-test-cluster ldap-scim-bridge wire-server-enterprise
- Fetch correct commit SHA from wire-server release tags
- Handle both annotated and lightweight tags
- Update version, commit, and commitURL for all pinned charts
- Fall back to version-only update if tag not found
Charts updated from 5.23.0 to 5.23.0:
wire-server redis-ephemeral redis-cluster rabbitmq rabbitmq-external databases-ephemeral fake-aws fake-aws-s3 fake-aws-sqs aws-ingress fluent-bit kibana backoffice calling-test demo-smtp elasticsearch-curator elasticsearch-external elasticsearch-ephemeral minio-external cassandra-external ingress-nginx-controller nginx-ingress-services reaper restund k8ssandra-test-cluster ldap-scim-bridge wire-server-enterprise
Major refactoring to improve maintainability, testability, and code organization.

## New Structure

- `.github/scripts/lib/common.sh` - Shared utility functions (174 lines)
  - Logging (log_info, log_success, log_warning, log_error)
  - Prerequisite checking
  - JSON operations (json_get, json_set)
  - GitHub API wrappers (get_commit_from_release)
  - Retry logic with exponential backoff
  - Git utilities

- `.github/scripts/pin-version.sh` - Version pinning script (213 lines)
  - Standalone script with --help documentation
  - Pins wire-server and related charts to specific versions
  - Fetches correct commit SHAs from wire-server releases
  - Updates both version numbers and commit metadata
  - Can be tested locally without GitHub Actions

- `.github/scripts/update-deploy-pr.sh` - Deploy PR script (352 lines)
  - Updates wire-server-deploy repository
  - Manages branch rebasing/recreation
  - Generates detailed commit messages with changelogs
  - Creates/updates PRs with version information
  - Testable locally with proper arguments

## Workflow Changes

- Reduced from 454 lines to 92 lines (79% reduction)
- Clean orchestration - just calls scripts
- No complex inline bash code
- Clear step boundaries

## Benefits

✅ Testable locally without GitHub Actions
✅ Better error handling with set -euo pipefail
✅ Colored logging for better readability
✅ Built-in retry logic for network operations
✅ Help documentation (--help flag)
✅ Modular and reusable code
✅ macOS compatible (fixed grep -P issues)
✅ DRY - no code duplication

## Documentation

- Updated README with branch lifecycle explanation
- Added "After Merging PRs" section
- Clarified CLI-based usage for offline branch
- Simplified structure focusing on offline branch

## Testing

All scripts tested locally:
- Common library functions ✅
- Version pinning logic ✅
- JSON manipulation ✅
- Error handling ✅
- GitHub API calls ✅
- macOS compatibility ✅

## Breaking Changes

None - workflow interface remains the same:
- Same triggers (push, PR, workflow_dispatch)
- Same inputs (wire_server_version dropdown)
- Same behavior (pins versions, creates PRs)
@sghosh23 sghosh23 merged commit 258718e into offline Dec 18, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants