ÃÛ¶¹ÊÓÆµ

Directory creation error in ÃÛ¶¹ÊÓÆµ Commerce on Cloud infrastructure

This article addresses the directory cannot be created error in ÃÛ¶¹ÊÓÆµ Commerce on Cloud infrastructure caused by a read-only file system. To fix this, update the .magento.env.yaml file with the correct language settings for static content deployment, save the changes, and redeploy the instance.

Description description

Environment

ÃÛ¶¹ÊÓÆµ Commerce on Cloud infrastructure

Issue/Symptoms

  • The system logs an error stating it cannot create a directory due to a read-only file system.

  • The error message appears as:

    Directory "/app/pub/static/frontend/< Namespace> /< Theme> /< locale> " cannot be created Warning! mkdir(): Read-only file system

  • The system fails to generate static content folders during runtime.

Resolution resolution

To resolve this issue, follow these steps:

  1. Open your .magento.env.yaml file.

  2. Check the SCD_MATRIX section to confirm that all required languages are listed for each theme. For example:

    code language-none
    SCD_MATRIX:
      "Theme_code1":
        language:
          - es_ES
          - en_US
      "Theme_code2":
        language:
          - es_ES
          - en_US
    
  3. Add any missing languages to ensure all used languages (such as en_US and es_ES) are included.

  4. Save the updated .magento.env.yaml file.

  5. Redeploy your ÃÛ¶¹ÊÓÆµ Commerce on Cloud infrastructure instance.

recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f