Install the CLI. See the install docs.
Log in:
runway login
Add an SSH key. See key setup, or use the shortcut:
runway local key setup
Let’s create an astro app and deploy it to Runway.
Create the project:
$ npm create astro@latest
...
The tool will guide you through several questions — anything is possible. The key thing to remember is to install the project in your desired location. Everything else, like choosing between TypeScript or JavaScript and setting up strictness levels, is entirely up to you.
We’ll assume, you installed into my-app, so let’s change into the directory and add a node adapter to your project:
$ cd my-app
$ npx astro add node
...
This will configure the build process as well, and allow us to run the app standalone.
Create the app on Runway:
$ runway app create
By default, astro’s build process will be “standalone” (vs. astro as part of another app) and create the artifact in the dist/server directory. Our next step is to configure your app to use this file to start:
$ npm pkg set scripts.start="node ./dist/server/entry.mjs"
npm run build and npm run start. Your app will be build and boot, and be available at http://localhost:4321.By default, an astro app runs on port 4321 and is accessible only on localhost. To deploy with Runway, add the PORT and HOST settings to your app’s configuration:
$ runway app config set PORT=4321 HOST=0.0.0.0
INFO configuring app "unique-eclipse"
configure app unique-eclipse: done
Name Value
HOST 0.0.0.0
PORT 4321
git-commit your changes before you proceed!runway app deploy
Run runway app open to see it live, or check the Runway UI. Check runway app logs if something’s off.
Congratulations, young astronaut! You’re app is on Runway! 🧑🏼🚀👨🏾🚀