当前位置:网站首页>Developer openshift4 Getting Started tutorial - 16 - use init container to mount pinpoint APM monitoring
Developer openshift4 Getting Started tutorial - 16 - use init container to mount pinpoint APM monitoring
2022-04-22 02:25:00 【East wind whistling】
tomcat erection of tank pinpoint-agent
- [ Get ready initcontainers Mirror image ]
Dockerfile file ( Write with reference to the mirror standard )
FROM alpine:latest
LABEL io.openshift.tags="pinpoint-agent"
RUN mkdir /pinpoint-agent \
&& chmod -R u+x /pinpoint-agent \
&& chmod -R g=u /pinpoint-agent /etc/passwd
ADD pinpoint-agent-1.8.4.tar.gz /pinpoint-agent/
CMD ["tail", "-f", "/dev/null"]
- [ to update yaml file ]
volumes:
- name: pinpoint-agent-1
emptyDir: {}
initContainers:
- name: pinpoint-agent
image: >-
image-registry.openshift-image-registry.svc:5000/pinpoint-agent-test/pinpoint-agent@sha256:4d703d7471e98eb4d66c6e76dc1079d536d7fc746d1a1b6f11e23514c7afde6d
command: ["sh", "-c", "cp -r /pinpoint-agent/* /deployments-pinpoint-agent"]
resources: {}
volumeMounts:
- name: pinpoint-agent-1
mountPath: /deployments-pinpoint-agent
So let's define a emptyDir Type of volume pinpoint-agent-1,initcontainers When the container starts , Put this pinpoint-agent-1 Mount the volume to /sharedFiles/AppServerAgent Catalog , And put the container in the mirror layer /pinpoint-agent Copy the files in the directory to pinpoint-agent-1 Under the volume , then initContainers The mission of , The normal exit .
containers:
- resources: {}
readinessProbe:
exec:
command:
- /bin/bash
- '-c'
- >-
curl --noproxy '*' -s -u J8KQ7u87:BxgGot20
'http://localhost:8080/manager/jmxproxy/?get=Catalina%3Atype%3DServer&att=stateName'
|grep -iq 'stateName *= *STARTED'
timeoutSeconds: 1
periodSeconds: 10
successThreshold: 1
failureThreshold: 3
terminationMessagePath: /dev/termination-log
name: jws-app
env:
- name: JWS_ADMIN_USERNAME
value: J8KQ7u87
- name: JWS_ADMIN_PASSWORD
value: BxgGot20
- name: PINPOINT_VERSION
value: 1.8.4
- name: AGENT_ID
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.name
- name: PROJECT_NAME
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
- name: JAVA_OPTS
value: >-
-javaagent:/deployments-pinpoint-agent/pinpoint-bootstrap-${PINPOINT_VERSION}-SNAPSHOT.jar
-Dpinpoint.agentId=${AGENT_ID}
-Dpinpoint.applicationName=${PROJECT_NAME}
ports:
- name: jolokia
containerPort: 8778
protocol: TCP
- name: http
containerPort: 8080
protocol: TCP
imagePullPolicy: Always
volumeMounts:
- name: pinpoint-agent-1
mountPath: /deployments-pinpoint-agent
terminationMessagePolicy: File
image: >-
image-registry.openshift-image-registry.svc:5000/pinpoint-agent-test/jws-app@sha256:3b6d7ad4c35d90ff44251ee1ff8f1fe5b3e6ebb55bf3db965d4462ea2490d83e
restartPolicy: Always
terminationGracePeriodSeconds: 60
dnsPolicy: ClusterFirst
securityContext: {}
schedulerName: default-scheduler
tomcat The container will pod Of namespace As APP_NAME name , take pod Of name As AGENT_ID, adopt JAVA_OPTS Variable configuration client related parameters .
notes : and initcontainers The container mounts the same pinpoint-agent-1 volume
版权声明
本文为[East wind whistling]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204211443192644.html
边栏推荐
- 14. System information viewing
- The advanced UI doesn't understand why they can get a high salary. It's hot
- Oracle表关联发散
- Leetcode-232 - queue implementation with stack
- Why won't MySQL lose data when the power is suddenly off? (Collection)
- 2022年物联网安全的发展趋势
- 【查看已经安装的包和命令是由哪个包提供的】
- 13. Installation mode of system software
- PV-TSM原理及matlab仿真
- What do you learn about programming
猜你喜欢

ENSP layer 3 switch connects layer 2 switch and router

JMeter + Jenkins + ant persistence

Scala installation and environment configuration

Redis cache database uses redis shake for data synchronization

Alibaba P9 explains high concurrency in detail, and shows you how Taobao can resist large-scale second kill activities such as double 11

算数四则混合运算表达式求值

What do you learn about programming
![[FAQ] Anaconda prompt reports an error. Solving environment: failed](/img/c9/e92a27b4150bcbc5ec1654f75a1b65.png)
[FAQ] Anaconda prompt reports an error. Solving environment: failed

102 page master plan for new generation digital transformation and informatization

STM32 FLASH操作
随机推荐
102 page master plan for new generation digital transformation and informatization
像堆乐高一样解释神经网络的数学过程
Shit, someone poisoned my code comments?
SV知识点回顾
2022年软件设计师考试知识点:线性表
嵌入式AI
flutter 音乐播放器audioplayer
Golang 1.8 generic testing
Detailed explanation of spark SQL underlying execution process
[pytorch image classification] alexnet network structure
Why is Nacos so strong
Opencv calculates the gradient feature of the image
Redis cache database uses redis shake for data synchronization
Explain various cloud computing models in detail. How can enterprises use each model to improve business productivity?
Page 107 planning and design of enterprise digital transformation
WSOLA原理及matlab仿真
面试题:用程序实现两个线程交替打印 0~100 的奇偶数
Unity Game Optimization - Third Edition 阅读笔记 Chapter 1 分析性能问题
postgresql中在查询结果中将字符串转换为整形或浮点型
吴恩达机器学习作业——逻辑回归