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

Bug: failure to connect to web hook #1409

Closed
iapaddler opened this issue Mar 29, 2023 · 0 comments · Fixed by #1411
Closed

Bug: failure to connect to web hook #1409

iapaddler opened this issue Mar 29, 2023 · 0 comments · Fixed by #1411
Assignees
Labels
bug Something isn't working k8s
Milestone

Comments

@iapaddler
Copy link
Contributor

$ docker build -t prom-exporter -f Dockerfile.exporter .
$ kind create cluster
$ kind load docker-image cribl/scope:dev
$ docker run -it --rm cribl/scope:dev scope k8s -c tcp://in.main-default-practical-leavitt.cribl.cloud:10091 | kubectl apply -f -
$ kubectl label namespace default scope=enabled
$ kubectl get pods

$ kind load docker-image prom-exporter:latest
$ kubectl apply -f exporter.yml
Error from server (InternalError): error when creating "exporter.yml": Internal error occurred: failed calling webhook "scope.default.appscope.io": failed to call webhook: Post "https://scope.default.svc:443/mutate?timeout=10s": EOF

exporter.yml
apiVersion: v1
kind: Pod
metadata:
name: prom-exporter
spec:
containers:

  • name: pexport
    image: prom-exporter
    command: ["sleep", "infinity"]
    imagePullPolicy: IfNotPresent
    volumeMounts:
    • name: prom-export
      mountPath: /hostfs
      volumes:
  • name: prom-export
    hostPath:
    path: /

Dockerfile.exporter :
FROM ubuntu:22.04

ENV DEBIAN_FRONTEND=noninteractive
RUN apt update
&& apt install -y
curl
emacs
gcc
gdb
lsof
vim
wget
&& rm -rf /var/lib/apt/lists/*

@iapaddler iapaddler added the k8s label Mar 29, 2023
@iapaddler iapaddler added this to the 1.3.2 milestone Mar 29, 2023
@iapaddler iapaddler added the bug Something isn't working label Mar 29, 2023
michalbiesek added a commit that referenced this issue Mar 29, 2023
- modify "imagePullPolicy": "IfNotPresent" for `scope-pod-extract`
- this fix would allow to avoid `ImagePullBackOff` status for
  Application pod in following scenario:
  - step 1 we preload the application image into cluster
  - step 2we deploy `scope k8s`
  - step 3we deploy application container
- This commit will modify `scope-pod-extract` behavior
  to use the image which was preloaded in step 1) instead of
  pulling the image from non-existent location

Fixes: #1409
michalbiesek added a commit that referenced this issue Mar 30, 2023
- use the same "imagePullPolicy" for `scope-pod-extract` as
  for Application container
- this fix would allow to avoid `ImagePullBackOff` status for
  Application pod in following scenario:
  - step 1 we preload the application image into cluster
  - step 2 we deploy `scope k8s`
  - step 3 we deploy application container
- This commit will modify `scope-pod-extract` behavior
  to use the image which was preloaded in step 1 instead of
  pulling the image from non-existent location

Fixes: #1409
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working k8s
Projects
No open projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants