windows 10 pro office 2019 pro office 365 pro windows 10 home windows 10 enterprise office 2019 home and business office 2016 pro windows 10 education visio 2019 microsoft project 2019 microsoft project 2016 visio professional 2016 windows server 2012 windows server 2016 windows server 2019 Betriebssysteme office software windows server https://softhier.com/ instagram takipçi instagram beğeni instagram görüntüleme instagram otomatik beğeni facebook beğeni facebook sayfa beğenisi facebook takipçi twitter takipçi twitter beğeni twitter retweet youtube izlenme youtube abone instagram

Shared Folder with Azure File on kubernetes pod doesn’t work

Asked By: Anonymous

I have an issue on my deployment when I try to share a folder with a kubernetes volume.
The folder will be shared using an Azure File Storage.
If I deploy my image without sharing the folder (/integrations) the app start.
as shown in the image below the pod via lens is up and running

If I add the relation of the folder to a volume the result is that the pod will stuck in error with this messagge

Here I put my yaml deployment:

apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: sandbox-pizzly
  name: sandbox-pizzly-widget
  labels:
    app: sandbox-pizzly-widget
    product: sandbox-pizzly
    app.kubernetes.io/name: "sandbox-pizzly-widget"
    app.kubernetes.io/version: "latest"
    app.kubernetes.io/managed-by: "xxxx"
    app.kubernetes.io/component: "sandbox-pizzly-widget"
    app.kubernetes.io/part-of: "sandbox-pizzly"
spec:
  replicas: 1
  selector:
    matchLabels:
      app: sandbox-pizzly-widget
  template:
    metadata:
      labels:
        app: sandbox-pizzly-widget
    spec:
      containers:
        - name: sandbox-pizzly-widget
          image: davidep931/pizzly-proxy:latest
          ports:
            - containerPort: 8080
          env:
            - name: NODE_ENV
              value: "production"
            - name: DASHBOARD_USERNAME
              value: "admin"
            - name: DASHBOARD_PASSWORD
              value: "admin"
            - name: SECRET_KEY
              value: "devSecretKey"
            - name: PUBLISHABLE_KEY
              value: "devPubKey"
            - name: PROXY_USES_SECRET_KEY_ONLY
              value: "FALSE"
            - name: COOKIE_SECRET
              value: "devCookieSecret"
            - name: AUTH_CALLBACK_URL
              value: "https://pizzly.mydomain/auth/callback"
            - name: DB_HOST
              value: "10.x.x.x"
            - name: DB_PORT
              value: "5432"
            - name: DB_DATABASE
              value: "postgresdb"
            - name: DB_USER
              value: "username"
            - name: DB_PASSWORD
              value: "password"
            - name: PORT
              value: "8080"
          volumeMounts:
            - mountPath: "/home/node/app/integrations"
              name: pizzlystorage
          resources:
            requests:
              memory: "100Mi"
              cpu: "50m"
            limits:
              cpu: "75m"
              memory: "200Mi"
---
apiVersion: v1
kind: Service
metadata:
  namespace: sandbox-pizzly
  name: sandbox-pizzly-widget
spec:
  ports:
    - port: 8080
      targetPort: 8080
  selector:
    app: sandbox-pizzly-widget
---
kind: PersistentVolume
apiVersion: v1
metadata:
  name: sandbox-pizzly-pv-volume
  labels:
    type: local
    app: products
spec:
  storageClassName: azurefile
  capacity:
    storage: 1Gi
  azureFile:
    secretName: azure-secret
    shareName: sandbox-pizzly-pv
    readOnly: false
    secretNamespace: sandbox-pizzly
  accessModes:
    - ReadWriteMany
  claimRef:
    namespace: sandbox-pizzly
    name: sandbox-pizzly-pv-claim
---
kind: PersistentVolumeClaim
apiVersion: v1
metadata:
  namespace: sandbox-pizzly
  name: sandbox-pizzly-pv-claim
  labels:
    app: products
spec:
  storageClassName: azurefile
  accessModes:
    - ReadWriteMany
  resources:
    requests:
      storage: 1Gi
---
kind: StorageClass
apiVersion: storage.k8s.io/v1
metadata:
  name: azurefilestorage
provisioner: kubernetes.io/azure-file
parameters:
  storageAccount: persistentsapizzly
reclaimPolicy: Retain
---
apiVersion: v1
kind: Secret
metadata:
  name: azure-secret
  namespace: sandbox-pizzly
type: Opaque
data:
  azurestorageaccountname: xxxxxxxxxxxxxxxxxxxxx
  azurestorageaccountkey: xxxxxxxxxxxxxxxxxxxxxxxxxxx

If I try, in the few seconds before the pod stuck, to access to integrations folder and I perform a touch ‘test.txt’, I will found that file in the Azure File Storage.

Here what I see few seconds before shell autoclose due to CrashLoopBack

I add the Dockerfile:

FROM node:14-slim

WORKDIR /app

# Copy in dependencies for building
COPY *.json ./
COPY yarn.lock ./
# COPY config ./config
COPY integrations ./integrations/
COPY src ./src/
COPY tests ./tests/
COPY views ./views/

RUN yarn install


# Actual image to run from.
FROM node:14-slim

# Make sure we have ca certs for TLS
RUN apt-get update && apt-get install -y 
    curl 
    wget 
    gnupg2 ca-certificates libnss3  
    git

# Make a directory for the node user. Not running Pizzly as root.
RUN mkdir /home/node/app && chown -R node:node /home/node/app
WORKDIR /home/node/app

USER node

# Startup script
COPY --chown=node:node ./startup.sh ./startup.sh
RUN chmod +x ./startup.sh
# COPY from first container
COPY --chown=node:node --from=0 /app/package.json ./package.json
COPY --chown=node:node --from=0 /app/dist/ .
COPY --chown=node:node --from=0 /app/views ./views
COPY --chown=node:node --from=0 /app/node_modules ./node_modules

# Run the startup script
CMD ./startup.sh

Here the startup.sh script:

#!/bin/sh

# Docker Startup script

# Apply migration
./node_modules/.bin/knex --cwd ./src/lib/database/config migrate:latest

# Start App
node ./src/index.js

Have you got any idea on what I miss or I’m wrong?

Thank you,
Dave.


Solution

Answered By: Anonymous

Well, there are two things I think you need to know when you mount the Azure file to the pods existing folder as the volume:

  1. it will cover the existing files
  2. the mount path will set the ownership as the root user

So the above means if your application will start depends on the existing files, then it will cause the problem. And if your application uses a non-root use, for example, the user app, then it maybe will also cause the problem. Here I guess the problem may be caused by the first limitation.

techinplanet staff

çanakkale escort erzincan escort van escort zonguldak escort kütahya escort osmaniye escort çorum escort giresun escort yozgat escort edirne escort uşak escort niğde escort amasya escort bolu escort kırıkkale escort karaman escort kırşehir escort sinop escort ısparta escort rize escort balıkesir escort kahramanmaraş escort trabzon escort erzurum escort batman escort elazığ escort tokat escort sivas escort mersin escort aydın escort manisa escort muğla escort tekirdağ escort urfa escort yalova escort fethiye escort

Windows 10 Kaufen Windows 10 Pro Office 2019 Kaufen Office 365 Lizenz Windows 10 Home Lizenz Office 2019 Home Business Kaufen windows office 365 satın al follower kaufen instagram follower kaufen porno

adana escort adapazarı escort adıyaman escort afşin escort afyon escort ağrı escort ahlat escort akçaabat escort akçakale escort akçakoca escort akdeniz escort akhisar escort aksaray escort akşehir escort aksu escort akyazı escort alanya escort alaşehir escort aliağa escort altıeylül escort altınordu escort amasya escort anamur escort ankara escort antakya escort antalya escort araklı escort ardahan escort ardeşen escort arnavutköy escort atakum escort avanos escort avcılar escort aydın escort ayvacık escort ayvalık escort aziziye escort babaeski escort bafra escort bağcılar escort bağlar escort balıkesir escort bandırma escort bartın escort batıkent escort batman escort battalgazi escort bayburt escort belek escort besni escort beylikdüzü escort beyşehir escort biga escort bilecik escort bingöl escort birecik escort bismil escort bitlis escort bodrum escort bolu escort bor escort bornova escort boyabat escort bozüyük escort buca escort bucak escort bulancak escort bulanık escort bünyan escort burdur escort bursa escort çan escort çanakkale escort canik escort çankaya escort çankırı escort çarşamba escort çayeli escort çekmeköy escort çerkeş escort çerkezköy escort çeşme escort ceyhan escort çivril escort çorlu escort çorum escort çubuk escort çukurova escort çumra escort dalaman escort darıca escort datça escort davutlar escort defne escort denizli escort derince escort develi escort didim escort digor escort dinar escort diyadin escort diyarbakır escort doğanşehir escort doğubayazıt escort dörtyol escort dulkadiroğlu escort düzce escort edirne escort edremit escort efeler escort elazığ escort elbistan escort emirdağ escort erbaa escort erdemli escort ereğli escort erenler escort ergani escort ergene escort erzincan escort erzurum escort escort esenler escort eskil escort eskişehir escort espiye escort eyyübiye escort fatih escort fatsa escort fethiye escort finike escort fındıklı escort gaziantep escort gaziemir escort gebze escort gediz escort gelibolu escort gemerek escort gemlik escort gerede escort giresun escort gölbaşı escort gölcük escort görele escort görükle escort göynük escort gümbet escort gümüşhane escort güngören escort güroymak escort gürsu escort hakkari escort haliliye escort hatay escort haymana escort horasan escort iğdır escort ilgaz escort i̇lkadım escort i̇negöl escort i̇skenderun escort isparta escort i̇stanbul escort i̇zmir escort i̇zmit escort i̇znik escort kadirli escort kadıköy escort kağıthane escort kağızman escort kahta escort kaman escort kangal escort kapaklı escort karabük escort karacabey escort karahayıt escort karaköprü escort karaman escort karatay escort karesi escort kars escort karşıyaka escort kartal escort kaş escort kastamonu escort kaynaşlı escort kayseri escort keçiören escort kemer escort kepez escort keşan escort keskin escort kestel escort kilis escort kırıkhan escort kırıkkale escort kırkağaç escort kırklareli escort kırşehir escort kızıltepe escort kocaeli escort kocasinan escort konak escort konya escort konyaaltı escort körfez escort korkuteli escort köyceğiz escort kozan escort kumluca escort kumru escort kuşadası escort kütahya escort lara escort lüleburgaz escort malatya escort malazgirt escort malkara escort maltepe escort mamak escort manavgat escort manisa escort maraş escort mardin escort marmaris escort melikgazi escort menemen escort menteşe escort meram escort mersin escort merzifon escort mezitli escort milas escort mucur escort mudanya escort mudurnu escort muğla escort muratpaşa escort muş escort mut escort nazilli escort nevşehir escort niğde escort niksar escort nilüfer escort nizip escort nurdağı escort ödemiş escort of escort oltu escort onikişubat escort ordu escort orhangazi escort ortahisar escort ortaköy escort osmancık escort osmangazi escort osmaniye escort palandöken escort pamukkale escort pamukova escort patnos escort payas escort pazar escort pazarcık escort pendik escort polatlı escort rize escort safranbolu escort şahinbey escort sakarya escort salihli escort samandağ escort samsun escort sandıklı escort şanlıurfa escort sapanca escort sarıçam escort sarıkamış escort sarıyer escort şarkışla escort şehitkamil escort selçuklu escort selim escort serdivan escort serik escort seyhan escort siirt escort silifke escort simav escort sincan escort sinop escort şişli escort sivas escort siverek escort şırnak escort söğüt escort söke escort soma escort sultangazi escort suluova escort sungurlu escort sur escort suruç escort suşehri escort susurluk escort talas escort tarsus escort taşova escort tavşanlı escort tekirdağ escort terme escort tire escort tirebolu escort tokat escort torbalı escort toroslar escort trabzon escort turgutlu escort turhal escort türkoğlu escort tuzla escort ulus escort ümraniye escort ünye escort ürgüp escort urla escort uşak escort üsküdar escort üzümlü escort van escort varto escort viranşehir escort yahşihan escort yahyalı escort yakutiye escort yalova escort yatağan escort yenişehir escort yeşilyurt escort yıldırım escort yıldızeli escort yomra escort yozgat escort yunusemre escort yüreğir escort zara escort zeytinburnu escort zile escort zonguldak escort mersin escort aydın escort manisa escort muğla escort tekirdağ escort urfa escort yalova escort fethiye escort