Netlify not recognising second package.json in repo and not installing dependencies

So my project structure is as follows:

Project Root
│
├── app/                      # Frontend directory
│   ├── public/               # Public assets
│   ├── src/                  # Source code
│   ├── server/               # Backend directory (moved inside the frontend directory)
│   │   ├── functions/        # Serverless functions directory
│   │   │   ├── function1.js  # Individual serverless functions
│   │   │   ├── function2.js
│   │   │   ├── ...
│   │   ├── package.json      # Backend dependencies
│   │   ├── ...               # Other backend files and directories
│   ├── package.json          # Frontend dependencies
│   ├── ...                   # Other frontend files and directories
│
├── netlify.toml              # Netlify configuration file
└── README.md                 # Project documentation

I know this structure is a bit disabled, but initially this project was root, and two subdirs, app and server

However netlify requires a base directory which I set as app/ and it requires a functions directory which they force to be inside whatever you set as your base directory. So therefore I moved my server dir inside my app dir.

Problem now is that in the netlify build, it isnt running npm install for the package.json inside server directory

Here are the logs for the build process

10:40:24 PM: Netlify Build                                                 
10:40:24 PM: ────────────────────────────────────────────────────────────────
10:40:24 PM: ​
10:40:24 PM: ❯ Version
10:40:24 PM:   @netlify/build 29.41.3
10:40:24 PM: ​
10:40:24 PM: ❯ Flags
10:40:24 PM:   baseRelDir: true
10:40:24 PM:   buildId: 663fe5a7bad0a341be052aed
10:40:24 PM:   deployId: 663fe5a7bad0a341be052aef
10:40:24 PM: ​
10:40:24 PM: ❯ Current directory
10:40:24 PM:   /opt/build/repo/app
10:40:24 PM: ​
10:40:24 PM: ❯ Config file
10:40:24 PM:   /opt/build/repo/netlify.toml
10:40:24 PM: ​
10:40:24 PM: ❯ Context
10:40:24 PM:   production
10:40:24 PM: ​
10:40:24 PM: build.command from netlify.toml                               
10:40:24 PM: ────────────────────────────────────────────────────────────────
10:40:24 PM: ​
10:40:24 PM: $ npm run build --ignore-warnings
10:40:25 PM: > [email protected] build
10:40:25 PM: > react-scripts build --ignore-warnings
10:40:26 PM: Creating an optimized production build...
10:40:35 PM: One of your dependencies, babel-preset-react-app, is importing the
10:40:35 PM: "@babel/plugin-proposal-private-property-in-object" package without
10:40:35 PM: declaring it in its dependencies. This is currently working because
10:40:35 PM: "@babel/plugin-proposal-private-property-in-object" is already in your
10:40:35 PM: node_modules folder for unrelated reasons, but it may break at any time.
10:40:35 PM: babel-preset-react-app is part of the create-react-app project, which
10:40:35 PM: is not maintianed anymore. It is thus unlikely that this bug will
10:40:35 PM: ever be fixed. Add "@babel/plugin-proposal-private-property-in-object" to
10:40:35 PM: your devDependencies to work around this error. This will make this message
10:40:35 PM: go away.
10:40:43 PM: Compiled with warnings.
10:40:43 PM: 
10:40:43 PM: [eslint]
10:40:43 PM: src/StockDetailsPage/Chart/utils.js
10:40:43 PM:   Line 155:1:  Assign object to a variable before exporting as module default  import/no-anonymous-default-export
10:40:43 PM: src/StockDetailsPage/Options/index.js
10:40:43 PM:   Line 34:8:  React Hook useEffect has a missing dependency: 'price'. Either include it or remove the dependency array  react-hooks/exhaustive-deps
10:40:43 PM: Search for the keywords to learn more about each warning.
10:40:43 PM: To ignore, add // eslint-disable-next-line to the line before.
10:40:43 PM: File sizes after gzip:
10:40:43 PM:   132.79 kB  build/static/js/main.93092ac4.js
10:40:43 PM:   46.67 kB   build/static/css/main.591ccc60.css
10:40:43 PM: The project was built assuming it is hosted at /.
10:40:43 PM: You can control this with the homepage field in your package.json.
10:40:43 PM: The build folder is ready to be deployed.
10:40:43 PM: You may serve it with a static server:
10:40:43 PM:   npm install -g serve
10:40:43 PM:   serve -s build
10:40:43 PM: Find out more about deployment here:
10:40:43 PM:   https://cra.link/deployment
10:40:44 PM: ​
10:40:44 PM: (build.command completed in 19.1s)
10:40:44 PM: ​
10:40:44 PM: Functions bundling                                            
10:40:44 PM: ────────────────────────────────────────────────────────────────
10:40:44 PM: ​
10:40:44 PM: Packaging Functions from server/functions directory:
10:40:44 PM:  - history.js
10:40:44 PM:  - options.js
10:40:44 PM:  - quote.js
10:40:44 PM:  - screener.js
10:40:44 PM:  - search.js
10:40:44 PM:  - suggestions.js
10:40:44 PM: ​
10:40:49 PM: ​
10:40:49 PM: (Functions bundling completed in 5.4s)
10:40:49 PM: ​
10:40:49 PM: (Netlify Build completed in 25s)
10:40:50 PM: Section completed: building
10:40:52 PM: Finished processing build request in 48.216s

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