Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: transform git tag with v format #865

Merged
merged 2 commits into from
Aug 18, 2022

Conversation

v1v
Copy link
Member

@v1v v1v commented Aug 17, 2022

What

Pipeline helper should be the one validating and transforming the given docker tag to the right format.

Why

This pipeline is called when a git tag release happens, and unfortunately those git tags follow the syntax v<major>.<minor>.<patch> where <major>, <minor> and <patch> are digits, i.e: v8.3.0 but the docker tag is required to be <major>.<minor>.<patch> based.

Rather than delegating to the consumers to do the manipulation, let's do the transformation if starting with v within the pipeline itself.

Fixes

image

@v1v v1v requested review from jsoriano, mrodm and a team August 17, 2022 16:29
@v1v v1v self-assigned this Aug 17, 2022
@elasticmachine
Copy link

elasticmachine commented Aug 17, 2022

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2022-08-18T08:33:22.082+0000

  • Duration: 5 min 37 sec

Test stats 🧪

Test Results
Failed 0
Passed 213
Skipped 0
Total 213

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

@v1v v1v changed the title ci: transform git tag with v format ci: transform git tag with v format Aug 17, 2022
Copy link
Contributor

@mrodm mrodm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Copy link
Member

@jsoriano jsoriano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@@ -11,7 +11,6 @@ pipeline {
DOCKER_REGISTRY_SECRET = 'secret/observability-team/ci/docker-registry/prod'
DOCKER_TAG = "${params.DOCKER_TAG}"
DOCKER_IMG_SOURCE = "${env.DOCKER_REGISTRY}/package-registry/distribution:production"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DOCKER_IMG_SOURCE is also only used in the publishing step, would it make sense to move this env variable also there?

Copy link

@amannocci amannocci left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@v1v v1v merged commit 3a32ddf into elastic:main Aug 18, 2022
mtojek pushed a commit to mtojek/package-registry that referenced this pull request Aug 24, 2022
mtojek added a commit that referenced this pull request Sep 6, 2022
* WIP

* Refactor indexer to proxy mode

* Prepare interfaces

* Link

* Bump github.com/prometheus/client_golang from 1.12.2 to 1.13.0 (#861)

Bumps [github.com/prometheus/client_golang](https://github.com/prometheus/client_golang) from 1.12.2 to 1.13.0.
- [Release notes](https://github.com/prometheus/client_golang/releases)
- [Changelog](https://github.com/prometheus/client_golang/blob/main/CHANGELOG.md)
- [Commits](prometheus/client_golang@v1.12.2...v1.13.0)

---
updated-dependencies:
- dependency-name: github.com/prometheus/client_golang
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump go.uber.org/zap from 1.21.0 to 1.22.0 (#862)

Bumps [go.uber.org/zap](https://github.com/uber-go/zap) from 1.21.0 to 1.22.0.
- [Release notes](https://github.com/uber-go/zap/releases)
- [Changelog](https://github.com/uber-go/zap/blob/master/CHANGELOG.md)
- [Commits](uber-go/zap@v1.21.0...v1.22.0)

---
updated-dependencies:
- dependency-name: go.uber.org/zap
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update favicon with the new EPR logo (#858)

Update favicon file with the new Elastic Package Registry logo.
A new "img" folder has also been added to include other
available formats of this new logo (png, svg and ico).

* Bump cloud.google.com/go/storage from 1.24.0 to 1.25.0 (#863)

Bumps [cloud.google.com/go/storage](https://github.com/googleapis/google-cloud-go) from 1.24.0 to 1.25.0.
- [Release notes](https://github.com/googleapis/google-cloud-go/releases)
- [Changelog](https://github.com/googleapis/google-cloud-go/blob/main/CHANGES.md)
- [Commits](googleapis/google-cloud-go@pubsub/v1.24.0...spanner/v1.25.0)

---
updated-dependencies:
- dependency-name: cloud.google.com/go/storage
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* ci: transform git tag with `v` format (#865)

* Bump github.com/fsouza/fake-gcs-server from 1.38.3 to 1.38.4 (#866)

Bumps [github.com/fsouza/fake-gcs-server](https://github.com/fsouza/fake-gcs-server) from 1.38.3 to 1.38.4.
- [Release notes](https://github.com/fsouza/fake-gcs-server/releases)
- [Commits](fsouza/fake-gcs-server@v1.38.3...v1.38.4)

---
updated-dependencies:
- dependency-name: github.com/fsouza/fake-gcs-server
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Use proxymode in main

* Search

* WIP: before resolver

* Resolver

* Basic resolver

* Fix: mage check

* Not needed

* Fix: imports

* Add CHANGELOG

* Categories

* Address PR comments

* Use consts

* More fixes

* Use snapshot registry

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mario Rodriguez Molins <mario.rodriguez@elastic.co>
Co-authored-by: Victor Martinez <victormartinezrubio@gmail.com>
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.

5 participants