Error after Deploying strapi 4.23.0 to google app engine with postgres DB

I have been trying to deploy my strapi application to google app engine, but getting the below error after deployment in the error logs

Error: ENOENT: no such file or directory, mkdir ‘/workspace/.tmp’
at Object.mkdirSync (node:fs:1373:26)
at module.exports.makeDirSync (/layers/google.nodejs.yarn/yarn_modules/node_modules/fs-extra/lib/mkdirs/make-dir.js:23:13)
at SqliteDialect.configure (/layers/google.nodejs.yarn/yarn_modules/node_modules/@strapi/database/dist/index.js:936:26)
at new Database (/layers/google.nodejs.yarn/yarn_modules/node_modules/@strapi/database/dist/index.js:6185:18)
at Database.init (/layers/google.nodejs.yarn/yarn_modules/node_modules/@strapi/database/dist/index.js:6170:16)
at Strapi.bootstrap (/layers/google.nodejs.yarn/yarn_modules/node_modules/@strapi/strapi/dist/Strapi.js:372:39)
at Strapi.load (/layers/google.nodejs.yarn/yarn_modules/node_modules/@strapi/strapi/dist/Strapi.js:426:16)

Below is the error I am seeing on the frontend:

https://10615.ew.r.appspot.com/

Service Unavailable

Below is the old guide I have followed to deploy

https://docs-v3.strapi.io/developer-docs/latest/setup-deployment-guides/deployment/hosting-guides/google-app-engine.html

Below is my config:

Package.json

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>{
"name": "backend",
"version": "0.1.0",
"private": true,
"description": "A Strapi application",
"license": "MIT",
"author": {
"name": "A Strapi developer"
},
"scripts": {
"build": "strapi build",
"develop": "strapi develop",
"gcp-build": "strapi build",
"start": "strapi start",
"strapi": "strapi"
},
"dependencies": {
"@strapi/plugin-i18n": "4.23.0",
"@strapi/plugin-seo": "^1.9.8",
"@strapi/plugin-users-permissions": "4.23.0",
"@strapi/strapi": "4.23.0",
"better-sqlite3": "8.6.0",
"pg": "^8.11.5",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"react-router-dom": "5.3.4",
"styled-components": "5.3.3"
},
"devDependencies": {},
"engines": {
"node": ">=18.0.0 <=20.x.x",
"npm": ">=6.0.0"
},
"strapi": {
"uuid": "4ab2-a874-3799d23b1640"
}
}
</code>
<code>{ "name": "backend", "version": "0.1.0", "private": true, "description": "A Strapi application", "license": "MIT", "author": { "name": "A Strapi developer" }, "scripts": { "build": "strapi build", "develop": "strapi develop", "gcp-build": "strapi build", "start": "strapi start", "strapi": "strapi" }, "dependencies": { "@strapi/plugin-i18n": "4.23.0", "@strapi/plugin-seo": "^1.9.8", "@strapi/plugin-users-permissions": "4.23.0", "@strapi/strapi": "4.23.0", "better-sqlite3": "8.6.0", "pg": "^8.11.5", "react": "^18.0.0", "react-dom": "^18.0.0", "react-router-dom": "5.3.4", "styled-components": "5.3.3" }, "devDependencies": {}, "engines": { "node": ">=18.0.0 <=20.x.x", "npm": ">=6.0.0" }, "strapi": { "uuid": "4ab2-a874-3799d23b1640" } } </code>
{
  "name": "backend",
  "version": "0.1.0",
  "private": true,
  "description": "A Strapi application",
  "license": "MIT",
  "author": {
    "name": "A Strapi developer"
  },
  "scripts": {
    "build": "strapi build",
    "develop": "strapi develop",
    "gcp-build": "strapi build",
    "start": "strapi start",
    "strapi": "strapi"
  },
  "dependencies": {
    "@strapi/plugin-i18n": "4.23.0",
    "@strapi/plugin-seo": "^1.9.8",
    "@strapi/plugin-users-permissions": "4.23.0",
    "@strapi/strapi": "4.23.0",
    "better-sqlite3": "8.6.0",
    "pg": "^8.11.5",
    "react": "^18.0.0",
    "react-dom": "^18.0.0",
    "react-router-dom": "5.3.4",
    "styled-components": "5.3.3"
  },
  "devDependencies": {},
  "engines": {
    "node": ">=18.0.0 <=20.x.x",
    "npm": ">=6.0.0"
  },
  "strapi": {
    "uuid": "4ab2-a874-3799d23b1640"
  }
}

app.yaml

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>runtime: nodejs18
instance_class: F2
env_variables:
HOST: '0.0.0.0'
NODE_ENV: 'production'
DATABASE_NAME: 'DB_NAME'
DATABASE_USERNAME: 'postgres'
DATABASE_PASSWORD: 'DB_PASS'
INSTANCE_CONNECTION_NAME: 'double-41web'
beta_settings:
cloud_sql_instances: 'double-41web'
</code>
<code>runtime: nodejs18 instance_class: F2 env_variables: HOST: '0.0.0.0' NODE_ENV: 'production' DATABASE_NAME: 'DB_NAME' DATABASE_USERNAME: 'postgres' DATABASE_PASSWORD: 'DB_PASS' INSTANCE_CONNECTION_NAME: 'double-41web' beta_settings: cloud_sql_instances: 'double-41web' </code>
runtime: nodejs18

instance_class: F2

env_variables:
  HOST: '0.0.0.0'
  NODE_ENV: 'production'
  DATABASE_NAME: 'DB_NAME'
  DATABASE_USERNAME: 'postgres'
  DATABASE_PASSWORD: 'DB_PASS'
  INSTANCE_CONNECTION_NAME: 'double-41web'

beta_settings:
  cloud_sql_instances: 'double-41web'

backend/config/env/production/database.js

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>module.exports = ({ env }) => ({
connection: {
client: "postgres",
connection: {
host: `/cloudsql/${env("INSTANCE_CONNECTION_NAME")}`,
database: env("DATABASE_NAME"),
user: env("DATABASE_USER"),
password: env("DATABASE_PASSWORD"),
},
},
});
</code>
<code>module.exports = ({ env }) => ({ connection: { client: "postgres", connection: { host: `/cloudsql/${env("INSTANCE_CONNECTION_NAME")}`, database: env("DATABASE_NAME"), user: env("DATABASE_USER"), password: env("DATABASE_PASSWORD"), }, }, }); </code>
module.exports = ({ env }) => ({
  connection: {
    client: "postgres",
    connection: {
      host: `/cloudsql/${env("INSTANCE_CONNECTION_NAME")}`,
      database: env("DATABASE_NAME"),
      user: env("DATABASE_USER"),
      password: env("DATABASE_PASSWORD"),
    },
  },
});

backend/.gcloudignore

Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
<code>.gcloudignore
.git
.gitignore
node_modules/
#!include:.gitignore
!.env
yarn.lock
</code>
<code>.gcloudignore .git .gitignore node_modules/ #!include:.gitignore !.env yarn.lock </code>
.gcloudignore
.git
.gitignore
node_modules/
#!include:.gitignore
!.env
yarn.lock

I have tried giving permission to some services:

role=roles/cloudsql.client

cloudsql.editor

storage.objectAdmin

appengine.deployer

logging.admin

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật