Issue Report for flyctl Deployment Failure (Error: unknown flag: --region)

Issue Report for flyctl Deployment Failure

It has been working since last week, and we didn’t change anything on the deployment script.

Problem Description

When attempting to deploy using flyctl, the deployment process failed with an error message indicating an unknown flag --region.

Steps to Reproduce

  1. Run the flyctl deploy command with the specified arguments and flags.
  2. Observe the deployment process.

Expected Behavior

The deployment process should complete successfully, deploying the application to the specified region without encountering any errors related to unknown flags.

Actual Behavior

The deployment process failed with an error message mentioning an unknown flag --region, preventing successful deployment.

Error Message

Error: unknown flag: --region

Command Used

flyctl deploy --dockerfile prod.Dockerfile --app app-fe --region lax --remote-only --build-arg API_URL=***

Additional Information

  • The deployment process is critical for our application’s release cycle.
  • We have verified that the specified flag --region is indeed valid according to the documentation.
  • This issue is blocking our deployment workflow and requires urgent resolution.

Troubleshooting Steps Taken

  • We have attempted to review the flyctl documentation to ensure correct usage of the --region flag.
  • We have inspected the command syntax and arguments for any typos or mistakes, but none were found.

Requested Support

We kindly request assistance in resolving this issue promptly so that we can resume our deployment operations. If there are any workarounds or alternative approaches to deploying please advise.

After updating to the latest flyctl version, I replaced the --region flag with --regions, which resolved my issue.

I use superfly/fly-pr-review-apps@1.2.0 to deploy preview apps and I’m facing the same issue now. How do I update the flyctl version?

flyctl v0.2.47 [PR] seems to have broken the above preview apps flow for the same Error: unknown flag: --region issue.

The --region flag had an unintended negative side effect in that it would override the primary_region setting in fly.toml. This surprising behavior bit us last week.

We just merged a PR to fix the fly-pr-review-apps action.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.