mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2026-02-11 00:51:11 +00:00
Update Dockerfile with log forwarder
Signed-off-by: lii5a <liisa.tallinn@gmail.com>
This commit is contained in:
parent
9ab6c941f8
commit
51a53691da
1 changed files with 7 additions and 0 deletions
|
|
@ -52,6 +52,13 @@ ENV OTEL_LOGS_EXPORTER=none
|
|||
# JVM options: attach the OTel Java agent
|
||||
ENV JAVA_TOOL_OPTIONS="-javaagent:/otel/otel-agent.jar"
|
||||
|
||||
# Copy log forwarder
|
||||
COPY forward-logs.sh /app/forward-logs.sh
|
||||
RUN chmod +x /app/forward-logs.sh
|
||||
|
||||
# Run PetClinic and log forwarder in same container
|
||||
ENTRYPOINT ["bash", "-c", "java -jar app.jar & /app/forward-logs.sh"]
|
||||
|
||||
# Expose PetClinic default port (usually 8080)
|
||||
EXPOSE 8080
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue