Deploying a new Module as Separate App to fly.io
I'm using the Open SaaS template. In the client module, I'd like to establish a new module that can be deployed as a separate app to fly.io or other providers. How can I accomplish this?
wasp build command in your project directory. This will create a .wasp/build/ directory with the built code..wasp/build/ directory and run the flyctl launch --remote-only command. This will set up a new app and create a fly.toml file. During this process, you'll be asked a series of questions, such as choosing a region and whether you'd like a database. flyctl secrets set command. .wasp/build/ directory, run the flyctl deploy --remote-only --config ../../fly.toml command. This will build and deploy your new module on Fly.io.<random_string_at_least_32_characters_long>, <url_of_where_client_will_be_deployed>, and <url_of_where_server_will_be_deployed> with your actual values.setup once per app. If you run it multiple times, it will create unnecessary apps on Fly.wasp new. Let me know if this works for you or this is not what you meant by “module” wasp build.wasp/build/.wasp/build/.wasp/build/flyctl launch --remote-onlyfly.tomlflyctl secrets setflyctl deploy --remote-only --config ../../fly.toml<random_string_at_least_32_characters_long><url_of_where_client_will_be_deployed><url_of_where_server_will_be_deployed>setupwasp new# Build the app
wasp build
# Navigate to the build directory
cd .wasp/build/
# Set up a new Fly.io app
flyctl launch --remote-only
# Set environment variables
flyctl secrets set PORT=8080
flyctl secrets set JWT_SECRET=<random_string_at_least_32_characters_long>
flyctl secrets set WASP_WEB_CLIENT_URL=<url_of_where_client_will_be_deployed>
flyctl secrets set WASP_SERVER_URL=<url_of_where_server_will_be_deployed>
# Deploy the app
flyctl deploy --remote-only --config ../../fly.toml