I have an odd one I think. I have a service that has three different config files for prod and staging and one as a base as well as dev:
In the prod version I have this entry:
xxxx.confluence.private.url = http://xxxx-prod
while in the staging version I have this entry: xxxx.confluence.private.url = http://xxxx-test
. When I execute my docker image in staging locally I have this output:
[io.quarkus] (main) Profile staging activated.
Sending request: http://xxxx-test
When I execute the same docker image on our k8s cluster I have this output:
[io.quarkus] (main) Profile staging activated.
Sending request: http://xxxx-prod
I set the profile using my deployment file using env variables:
env:
- name: QUARKUS_PROFILE
value: staging
The prod.properties is the only place in my code which contains this specific line, meaning its definetly the one being used when resolving properties. Why does this happen and how can I change this behaviour?
Edit:
My entire deployment file:
apiVersion: apps/v1
kind: Deployment
metadata:
name: calendar-service
labels:
app: calendar-service
spec:
replicas: 1
selector:
matchLabels:
app: calendar-service
template:
metadata:
labels:
app: calendar-service
spec:
containers:
- name: calendar-service
image: xxxx:k8s
ports:
- containerPort: 8080
protocol: TCP
env:
- name: QUARKUS_PROFILE
value: staging
imagePullSecrets:
- name: xxxx
CodePudding user response:
This morning I restarted the deployment and it now appears to be working. I suspect there was some delay in our registry but I can not say for certain