Closed m-adrees closed 1 year ago
Hi @adrees-scytalelabs, thanks for opening this issue - Just to confirm, does the 404 only happen when you deploy to Amplify? In other words, is it working locally?
yes, it is working locally fine.
@adrees-scytalelabs 👋 , apologies for the delayed response. The 404 error occurs as we did not detect an index.html file within the baseDirectory
of your buildSpec (amplify.yml file). Kindly modify your buildSpec
as follows to set the baseDirectory
to build
and then redeploy your Amplify app:
version: 1
frontend:
phases:
preBuild:
commands:
- npm ci
build:
commands:
- npm run build
artifacts:
baseDirectory: build
files:
- '**/*'
cache:
paths:
- node_modules/**/*
This issue has not received a response in a while. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Before opening, please confirm:
JavaScript Framework
React
Amplify APIs
Not applicable
Amplify Categories
No response
Environment information
Describe the bug
I have deployed a website using AWS amplify and the build was successful but I am getting an HTTP ERROR 404 https://main.d3i9rhg2l51kv8.amplifyapp.com/
Expected behavior
it should not be an error when we hit the link... it must be a website i deployed
Reproduction steps
connected the repo to the GitHub repo
Code Snippet
here is my package.json
Log output
aws-exports.js
No response
Manual configuration
No response
Additional configuration
No response
Mobile Device
No response
Mobile Operating System
No response
Mobile Browser
No response
Mobile Browser Version
No response
Additional information and screenshots
No response