aws-amplify / aws-amplify/amplify-hosting
Getting error "Unknown command: config"
- Dominant language
- Dockerfile
- Stars
- 481
- Forks
- 123
- PR merge metrics
- No merged PRs in 30d
Description
### Environment information
```plain text
System:
OS: Windows 10 10.0.19045
CPU: (12) x64 AMD Ryzen 5 5500
Memory: 11.39 GB / 31.80 GB
Binaries:
Node: 18.20.4 - ~\AppData\Local\nvs\default\node.EXE
Yarn: 1.22.17 - ~\AppData\Roaming\npm\yarn.CMD
npm: 8.19.2 - ~\Documents\path\to\repo\node_modules\.bin\npm.CMD
pnpm: undefined - undefined
NPM Packages:
@aws-amplify/auth-construct: 1.3.1
@aws-amplify/backend: 1.3.0
@aws-amplify/backend-auth: 1.2.0
@aws-amplify/backend-cli: 1.2.8
@aws-amplify/backend-data: 1.1.4
@aws-amplify/backend-deployer: 1.1.4
@aws-amplify/backend-function: 1.5.0
@aws-amplify/backend-output-schemas: 1.2.0
@aws-amplify/backend-output-storage: 1.1.2
@aws-amplify/backend-secret: 1.1.3
@aws-amplify/backend-storage: 1.2.0
@aws-amplify/cli-core: 1.1.3
@aws-amplify/client-config: 1.3.2
@aws-amplify/deployed-backend-client: 1.4.1
@aws-amplify/form-generator: 1.0.3
@aws-amplify/model-generator: 1.0.8
@aws-amplify/platform-core: 1.1.0
@aws-amplify/plugin-types: 1.3.0
@aws-amplify/sandbox: 1.2.2
@aws-amplify/schema-generator: 1.2.4
aws-amplify: 6.6.2
aws-cdk: 2.159.1
aws-cdk-lib: 2.159.1
typescript: 5.5.2
AWS environment variables:
AWS_NODEJS_CONNECTION_REUSE_ENABLED = 1
AWS_SDK_LOAD_CONFIG = 1
AWS_STS_REGIONAL_ENDPOINTS = regional
No CDK environment variables
```
### Describe the bug
I'm trying to deploy to an amplify app using S3 buckets, not a repo (we're just doing feasibility / investigation POC).
So everything has been zipped, and uploaded to S3, then selecting S3 bucket, then that zip when deploying updates.
We are zipping up the build outputs only, not the full repo. The site loads fine, but now it comes to implementing backend.
But I cannot find much documentation or help for setting up the "backend" with manual deployment, as all examples use git repos with the "app settings" page.
The only thing I can find is this page:
`https://eu-north-1.console.aws.amazon.com/amplify/apps//branches/staging/backend-help`
Which tells me to run a `npx ampx generate config` command.
However, when running that command, the help text of the command is printed, followed by `"Error: Unknown command: config"`.
`config` is not listed as an available command for `ampx generate`, so I am wondering if there is a recent update has changed things.
It's not listed here either: https://docs.amplify.aws/react/reference/cli-commands/#npx-ampx-generate
I cannot find anyone else facing this problem elsewhere. I have been searching extensively.
### Reproduction steps
This is the command I'm running (with \ replaced), with the output:
```
npx amplify generate config --app-id --branch staging
ampx generate
Generates post deployment artifacts
Commands:
ampx generate outputs Generates Amplify backend outputs
ampx generate forms Generates UI forms
ampx generate graphql-client-code Generates graphql API code
ampx generate schema-from-database Generates typescript data schema from a SQ
L database
Options:
--debug Print debug logs to the console [boolean] [default: false]
--help Show help [boolean]
--profile An AWS profile name. [string]
Error: Unknown command: config
```
Contributor guide
Research direction
Start with the AWS Amplify console's backend-help page, the documented npx ampx generate command, and the installed @aws-amplify/backend-cli 1.2.8 help output. Reproduce the reported config error using the command and environment details, then determine whether the CLI behavior or the documentation is wrong. Done means the manual S3 deployment path has a supported command or corrected guidance.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, node.js
- Domain
- backend, cli, cloud
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100