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

[chore] Build and publish application hosted in the repository for the Python instrumentation E2E test #2095

Merged
merged 21 commits into from
Oct 4, 2023
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
6fd672a
Build and publish the Python E2E image
iblancasa Sep 6, 2023
7fe5344
Fix archs
iblancasa Sep 6, 2023
135afca
Merge branch 'main' into task/2073-python
iblancasa Sep 14, 2023
5ff905c
Fix the tags
iblancasa Sep 14, 2023
e65d632
Merge branch 'task/2073-python' of github.com:iblancasa/opentelemetry…
iblancasa Sep 14, 2023
32aaccd
Merge branch 'main' of github.com:open-telemetry/opentelemetry-operat…
iblancasa Sep 14, 2023
f5b6b05
Fix the tags
iblancasa Sep 14, 2023
473055b
Merge branch 'main' into task/2073-python
iblancasa Sep 18, 2023
c1ace18
Merge branch 'main' into task/2073-python
iblancasa Sep 20, 2023
47d60d1
Merge branch 'task/2073-python' of github.com:iblancasa/opentelemetry…
iblancasa Sep 29, 2023
0008c45
Merge branch 'main' of github.com:open-telemetry/opentelemetry-operat…
iblancasa Sep 29, 2023
09530ea
Use reusable workflow
iblancasa Sep 29, 2023
386b0c2
Fix workflow name
iblancasa Sep 29, 2023
479d47e
Merge branch 'main' of github.com:open-telemetry/opentelemetry-operat…
iblancasa Oct 2, 2023
b7f5e88
Merge branch 'main' of github.com:open-telemetry/opentelemetry-operat…
iblancasa Oct 2, 2023
c01e90a
Merge branch 'main' into task/2073-python
iblancasa Oct 2, 2023
b3aaacd
Merge branch 'main' into task/2073-python
iblancasa Oct 3, 2023
f13cbf2
Merge branch 'task/2073-python' of github.com:iblancasa/opentelemetry…
iblancasa Oct 3, 2023
cc48d21
Merge branch 'main' of github.com:open-telemetry/opentelemetry-operat…
iblancasa Oct 3, 2023
b6ec318
Merge branch 'task/2073-python' of github.com:iblancasa/opentelemetry…
iblancasa Oct 4, 2023
bf2b262
Merge branch 'main' of github.com:open-telemetry/opentelemetry-operat…
iblancasa Oct 4, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions .github/workflows/publish-autoinstrumentation-e2e-images.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: "Publish instrumentation E2E images"

on:
push:
paths:
- 'tests/instrumentation-e2e-apps/**'
- '.github/workflows/publish-autoinstrumentation-e2e-images.yaml'
branches:
- main
pull_request:
paths:
- 'tests/instrumentation-e2e-apps/**'
- '.github/workflows/publish-autoinstrumentation-e2e-images.yaml'
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
cancel-in-progress: true

jobs:
python:
runs-on: ubuntu-20.04

steps:
- uses: actions/checkout@v3

- name: Docker meta
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/open-telemetry/opentelemetry-operator/python-test

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Cache Docker layers
uses: actions/cache@v3
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ github.sha }}
restore-keys: |
${{ runner.os }}-buildx-
- name: Login to GitHub Package Registry
uses: docker/login-action@v2
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push
uses: docker/build-push-action@v4
with:
context: tests/instrumentation-e2e-apps/python
platforms: linux/arm64,linux/amd64,linux/s390x,linux/ppc64le
push: ${{ github.event_name == 'push' }}
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache
7 changes: 7 additions & 0 deletions tests/instrumentation-e2e-apps/python/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
FROM python:alpine3.18

COPY requirements.txt .
RUN pip install -r requirements.txt
COPY app.py .

ENTRYPOINT ["flask", "run", "-p", "8080"]
10 changes: 10 additions & 0 deletions tests/instrumentation-e2e-apps/python/app.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
from flask import Flask

app = Flask(__name__)

@app.route('/')
def index():
return "Hi"

if __name__ == "__main__":
app.run(host='0.0.0.0')
iblancasa marked this conversation as resolved.
Show resolved Hide resolved
1 change: 1 addition & 0 deletions tests/instrumentation-e2e-apps/python/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Flask==2.3.3
Loading