Skip to content

Commit

Permalink
Update to e50f5d9
Browse files Browse the repository at this point in the history
  • Loading branch information
mapno committed Dec 19, 2024
1 parent db7d2df commit 580ff7a
Show file tree
Hide file tree
Showing 307 changed files with 9,087 additions and 5,724 deletions.
23 changes: 0 additions & 23 deletions .drone/drone.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -207,29 +207,6 @@ local deploy_to_dev() = {
for arch in archs
],
},
] + [
// Publish tools Docker manifests
(
pipeline('docker-ci-tools-%s' % arch, arch) {
steps+: [
image_tag(arch),
docker_build(arch, 'tempo-ci-tools', dockerfile='tools/Dockerfile'),
],
}
)
for arch in archs
] + [
// Publish Docker manifests
pipeline('manifest-ci-tools') {
steps+: [
image_tag(),
docker_manifest('tempo-ci-tools'),
],
depends_on+: [
'docker-ci-tools-%s' % arch
for arch in archs
],
},
] + [
// Continuously Deploy to dev env
pipeline('cd-to-dev-env') {
Expand Down
100 changes: 1 addition & 99 deletions .drone/drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -212,104 +212,6 @@ trigger:
- refs/heads/r??
- refs/heads/r???
---
depends_on: []
kind: pipeline
name: docker-ci-tools-amd64
platform:
arch: amd64
os: linux
steps:
- commands:
- apk --update --no-cache add bash
- git fetch origin --tags
- echo $(./tools/image-tag)-amd64 > .tags
image: alpine/git:v2.30.2
name: image-tag
- image: plugins/docker
name: build-tempo-ci-tools-image
settings:
build_args:
- TARGETARCH=amd64
dockerfile: tools/Dockerfile
password:
from_secret: docker_password
platform: linux/amd64
repo: grafana/tempo-ci-tools
username:
from_secret: docker_username
trigger:
ref:
- refs/heads/main
- refs/tags/v*
- refs/heads/r?
- refs/heads/r??
- refs/heads/r???
---
depends_on: []
kind: pipeline
name: docker-ci-tools-arm64
platform:
arch: arm64
os: linux
steps:
- commands:
- apk --update --no-cache add bash
- git fetch origin --tags
- echo $(./tools/image-tag)-arm64 > .tags
image: alpine/git:v2.30.2
name: image-tag
- image: plugins/docker
name: build-tempo-ci-tools-image
settings:
build_args:
- TARGETARCH=arm64
dockerfile: tools/Dockerfile
password:
from_secret: docker_password
platform: linux/arm64
repo: grafana/tempo-ci-tools
username:
from_secret: docker_username
trigger:
ref:
- refs/heads/main
- refs/tags/v*
- refs/heads/r?
- refs/heads/r??
- refs/heads/r???
---
depends_on:
- docker-ci-tools-amd64
- docker-ci-tools-arm64
kind: pipeline
name: manifest-ci-tools
platform:
arch: amd64
os: linux
steps:
- commands:
- apk --update --no-cache add bash
- git fetch origin --tags
- echo $(./tools/image-tag) > .tags
image: alpine/git:v2.30.2
name: image-tag
- image: plugins/manifest:1.4.0
name: manifest-tempo-ci-tools
settings:
password:
from_secret: docker_password
spec: .drone/docker-manifest.tmpl
target: tempo-ci-tools
username:
from_secret: docker_username
trigger:
ref:
- refs/heads/main
- refs/tags/v*
- refs/heads/r?
- refs/heads/r??
- refs/heads/r???
---
depends_on:
- manifest
image_pull_secrets:
Expand Down Expand Up @@ -597,6 +499,6 @@ kind: secret
name: gpg_passphrase
---
kind: signature
hmac: 0265cd585d8c7fc444bebc8aa1164ec6aa7893c2aa16f3beb61503102b00a798
hmac: 13b44a917ac76c853b2c406c6302005f6de74ea58c78564f79a7baab606a84d8

...
2 changes: 1 addition & 1 deletion .github/workflows/add-to-docs-project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ jobs:
permissions:
contents: read
id-token: write
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- uses: grafana/writers-toolkit/add-to-docs-project@add-to-docs-project/v1
2 changes: 1 addition & 1 deletion .github/workflows/backport.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ on:

jobs:
main:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Checkout Actions
uses: actions/checkout@v4
Expand Down
36 changes: 27 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@ concurrency:
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:

- name: Check out code
uses: actions/checkout@v4
with:
Expand All @@ -29,18 +30,32 @@ jobs:
uses: actions/setup-go@v5
with:
go-version-file: "go.mod"

- name: check-fmt
run: make check-fmt

- name: check-jsonnetfmt
run: make check-jsonnetfmt

- name: Get year and week number
id: get-year-week-number
run: echo "date=$(date +"%Yweek%U")" >> $GITHUB_OUTPUT

- name: cache golangci
uses: actions/cache@v4
with:
path: .cache/golangci-lint
key: golangci-lint-${{ runner.os }}-${{ steps.get-year-week-number.outputs.date }}-${{ hashFiles('go.mod', '.golangci.yml') }}

- name: lint
run: make lint base=origin/${{github.base_ref}}
run: |
make lint base=origin/${{github.base_ref}}
sudo chown -R $(id -u):$(id -g) .cache/golangci-lint # needed to archive cache
unit-tests:
name: Run Unit Tests
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
strategy:
matrix:
test-target:
Expand All @@ -65,7 +80,7 @@ jobs:

integration-tests:
name: Run integration tests
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
strategy:
matrix:
test-target:
Expand All @@ -90,7 +105,7 @@ jobs:

build:
name: Build
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Check out code
uses: actions/checkout@v4
Expand All @@ -103,6 +118,9 @@ jobs:
- name: Build Tempo
run: make tempo

- name: generate-manifest
run: make generate-manifest

- name: Build tempo-query
run: make tempo-query

Expand All @@ -114,7 +132,7 @@ jobs:

benchmark:
name: Benchmark
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Check out code
uses: actions/checkout@v4
Expand All @@ -129,7 +147,7 @@ jobs:

vendor-check:
name: Vendor check
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Check out code
uses: actions/checkout@v4
Expand All @@ -147,7 +165,7 @@ jobs:

tempo-jsonnet:
name: Check jsonnet & tempo-mixin
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Check out code
uses: actions/checkout@v4
Expand All @@ -168,7 +186,7 @@ jobs:

build-technical-documentation:
name: Build technical documentation
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
steps:
- name: Check out code
uses: actions/checkout@v4
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/dependabot_serverless_gomod.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@ permissions:
jobs:
dependabot:
name: Serverless gomod update
runs-on: ubuntu-latest
if: ${{ github.event.pull_request.user.login == 'tempo-gh-bot[bot]' }}
runs-on: ubuntu-24.04
if: ${{ github.event.pull_request.user.login == 'dependabot[bot]' }}
steps:
- name: Set up Go 1.22
- name: Set up Go 1.23
uses: actions/setup-go@v5
with:
go-version: 1.23.1
go-version: 1.23.3

- name: Get app token
uses: actions/create-github-app-token@v1
Expand All @@ -44,6 +44,8 @@ jobs:
USER: x-access-token
TOKEN: ${{ steps.get-github-app-token.outputs.token }}
run: |
git config --global user.email "[email protected]"
git config --global user.name "tempo-gh-bot[bot]"
git config --global url."https://${USER}:${TOKEN}@github.com/grafana/tempo".insteadOf "https://github.com/grafana/tempo"
git add cmd/tempo-serverless/lambda/go.mod
git add cmd/tempo-serverless/lambda/go.sum
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/doc-validator.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
workflow_dispatch:
jobs:
doc-validator:
runs-on: "ubuntu-latest"
runs-on: "ubuntu-24.04"
container:
image: "grafana/doc-validator:v5.2.0"
steps:
Expand Down
79 changes: 79 additions & 0 deletions .github/workflows/docker-ci-tools.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
name: docker-ci-tools
on:
push:
branches:
- 'main'
paths:
- 'tools/**'

env:
IMAGE_NAME: grafana/tempo-ci-tools

# Needed to login to DockerHub
permissions:
contents: read
id-token: write

jobs:

get-image-tag:
if: github.repository == 'grafana/tempo' # skip in forks
runs-on: ubuntu-24.04
outputs:
tag: ${{ steps.get-tag.outputs.tag }}
steps:
- name: Checkout
uses: actions/checkout@v4

- id: get-tag
run: |
echo "tag=$(./tools/image-tag)" >> "$GITHUB_OUTPUT"
docker-ci-tools:
if: github.repository == 'grafana/tempo'
needs: get-image-tag
strategy:
matrix:
runner_arch: [ { runner: ubuntu-24.04, arch: amd64 }, { runner: github-hosted-ubuntu-arm64, arch: arm64 } ]
runs-on: ${{ matrix.runner_arch.runner }}
env:
TAG: ${{ needs.get-image-tag.outputs.tag }}
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Login to DockerHub
uses: grafana/shared-workflows/actions/[email protected]

- name: docker-build-and-push
run: |
TAG_ARCH="$TAG-${{ matrix.runner_arch.arch }}"
docker build -f tools/Dockerfile -t $IMAGE_NAME:$TAG_ARCH .
docker push $IMAGE_NAME:$TAG_ARCH
manifest:
if: github.repository == 'grafana/tempo'
needs: ['get-image-tag', 'docker-ci-tools']
runs-on: ubuntu-latest
env:
TAG: ${{ needs.get-image-tag.outputs.tag }}
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Login to DockerHub
uses: grafana/shared-workflows/actions/[email protected]

- name: docker-manifest-create-and-push
run: |
docker manifest create \
$IMAGE_NAME:$TAG \
--amend $IMAGE_NAME:$TAG-amd64 \
--amend $IMAGE_NAME:$TAG-arm64
docker manifest push $IMAGE_NAME:$TAG
docker manifest create \
$IMAGE_NAME:latest \
--amend $IMAGE_NAME:$TAG-amd64 \
--amend $IMAGE_NAME:$TAG-arm64
docker manifest push $IMAGE_NAME:latest
5 changes: 5 additions & 0 deletions .github/workflows/drone-signature-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,13 @@ on:
paths:
- ".drone/drone.yml"

permissions:
id-token: write

jobs:
drone-signature-check:
# only run in grafana/tempo.
if: github.repository == 'grafana/tempo'
uses: grafana/shared-workflows/.github/workflows/check-drone-signature.yaml@main
with:
drone_config_path: .drone/drone.yml
Loading

0 comments on commit 580ff7a

Please sign in to comment.