Deploy to Galaxy
Learn how to deploy on Galaxy by setting up Push to Deploy. The easiest and fastest way of deploying your Meteor app.
You need a Meteor account in order to deploy your apps. If you don't have one yet, you can sign up here.
Start by going to your Meteor account on Galaxy. Then click on "Create New" > "Deploy App" on the top right corner.
Once there, you'll see this configuration page:
Click on the Git provider where is your project is located and install the our Git Application. We do support GitHub, Bitbucket and GitLab. An authentication popup from your Git provider show up. On this popup, you can choose the individual account or organization that you want to give us access to. You don't need to give access to all your repositories if you don't want to. Later you can go on Git provider and change your permissions to authorize more repositories.
After connecting to your Git provider, you'll automatically go to the second step. In the second step, you need to choose your account from the git provider and then choose the repository where the Meteor app you want to deploy is located.
Now just click on Next Step and you'll get to the third step.
In this step, you just need to configure to which Account your app will be deployed and which Plan you want to use. You can check everything about the plans on our pricing page.
We do not recommend deploying production applications to the Free plan as it provides only a limited container which is turned off when your app is not being used.
The Container Size needs to be selected as well. For paid apps, we recommend starting with the Compact size. You can change this at any time by going to your app page on Galaxy and selecting a different size.
You also need to select a Region. This is really important and your database should be in the same region to avoid latency and slowness in your app.
In the last step, it's time to choose your hostname, the domain of your app. If you are using the free plan, you need to use meteorapp.com as the main domain, and you can choose only the subdomain. If you are using a paid plan, you can use any domain you like. In this case, you also need to set up your DNS. Learn how here.
You can choose which branch you'll use as your deploy branch. Every commit done on this branch will trigger a new deployment. In this section, you can also choose to use our shared MongoDB Cluster.
Make sure you are not using this shared database for production apps. Learn more about our Fair Usage Policy.
There is another section for Advanced Options, where you can configure these options:
- Build Container RAM: Defines how much memory you want to use to deploy your app.
- Meteor Settings: Your initial app settings (in JSON format) when deploying an app.
- Root Directory: Directory in your repository where the root of your Meteor app is.
- Pre Deploy Command: Command you run to install the app's dependencies, usually meteor npm install --production.
- Deploy Arguments: Arguments you can provide to your deploy command line.
- Environment Variables: You can specify the region where your app will be deployed.
With everything configured, just hit Deploy and the first version of your app will be deployed!
You need to have a GitHub/Bitbucket/GitLab repository with a Meteor project. The following Meteor versions are supported: 1.12.2, 2.0.1, 2.1.2, 2.2.4, 2.3.7, and any version from 2.4.1 to the latest. Otherwise, you will see an error in the logs of your app on Galaxy.
On the app details page, you can click on the button Set up push to deploy.
The first two steps in this case are the same as deploying a new app. You will just have to connect your Git Provider, and then choose the repository. For the last step, make sure that everything is correct in the Deploy Options section. As the app is already deployed, all the other fields are already defined.
After configuring everything, if you need to edit it, you can click the Set up push to deploy button on the app details page.
Previously called Next auto deploy settings.
After configuring Push to Deploy for an app, you can find in Galaxy, on the settings tab, the title Override Meteor Settings. When you toggle the Override Settings and fill in the field below, on the next deploy, its content will be used instead of the settings.json file. After this deployment, if you change the settings.json file from the app and deploy it again, the JSON file from the app will still be ignored, and Galaxy will continue using the value from the field. To read the settings from the JSON file, you must untoggle the Override Settings.
The cost for deployments varies depending on which plan you are using on Galaxy.
- Free plan: No cost for deploys, but limited to 10 deploys per month.
- Essentials plan: Cost is the amount of time deploying x amount of GBs of memory x $0.08.
- Professional plan: Cost is the amount of time deploying x amount of GBs of memory x $0.11.
For example, if you spend 15 minutes on deployments using 3GBs of memory for an app in the Essential plan, the cost added to your invoice would be: 0.25h x 3GBs x $0.08 = $0.06.
If you want to use your own machines to build and deploy your apps, you can use the command-line.
1. How to trigger new deploys?
After you finish setting up everything, every commit you do to the chosen branch will trigger a new deploy. Also, every time you save the configuration, a new deploy will be triggered.
2. Can I use the repository and branch for different apps?
Yes, you can. Be careful when setting up your apps to avoid deploying the wrong code to an app.
3. What happens if a new commit is pushed before the previous deploy is completed?
The previous deploy will be canceled, and the new one will start.
4. How can I cancel a deploy that is in progress?
You can't. For now, the only way a deploy is canceled is if a new commit arrives or if the deploy fails.
5. What does docker error 137 mean?
This error means there was an Out Of Memory error. To solve this, increase the amount of memory you use to deploy your app. You can do this on the third step of the Push to Deploy screen, in the Deploy options > Build Container RAM section.
- Learn how to deploy applications with the command-line.
- Learn how to configure applications on Galaxy.
Sign up for Meteor Accounts
You need a Meteor account in order to deploy your apps. If you don't have one yet, you can sign up here.
Deploy a new app
Start by going to your Meteor account on Galaxy. Then click on "Create New" > "Deploy App" on the top right corner.
Once there, you'll see this configuration page:
Click on the Git provider where is your project is located and install the our Git Application. We do support GitHub, Bitbucket and GitLab. An authentication popup from your Git provider show up. On this popup, you can choose the individual account or organization that you want to give us access to. You don't need to give access to all your repositories if you don't want to. Later you can go on Git provider and change your permissions to authorize more repositories.
After connecting to your Git provider, you'll automatically go to the second step. In the second step, you need to choose your account from the git provider and then choose the repository where the Meteor app you want to deploy is located.
Now just click on Next Step and you'll get to the third step.
In this step, you just need to configure to which Account your app will be deployed and which Plan you want to use. You can check everything about the plans on our pricing page.
We do not recommend deploying production applications to the Free plan as it provides only a limited container which is turned off when your app is not being used.
The Container Size needs to be selected as well. For paid apps, we recommend starting with the Compact size. You can change this at any time by going to your app page on Galaxy and selecting a different size.
You also need to select a Region. This is really important and your database should be in the same region to avoid latency and slowness in your app.
In the last step, it's time to choose your hostname, the domain of your app. If you are using the free plan, you need to use meteorapp.com as the main domain, and you can choose only the subdomain. If you are using a paid plan, you can use any domain you like. In this case, you also need to set up your DNS. Learn how here.
You can choose which branch you'll use as your deploy branch. Every commit done on this branch will trigger a new deployment. In this section, you can also choose to use our shared MongoDB Cluster.
Make sure you are not using this shared database for production apps. Learn more about our Fair Usage Policy.
There is another section for Advanced Options, where you can configure these options:
- Build Container RAM: Defines how much memory you want to use to deploy your app.
- Meteor Settings: Your initial app settings (in JSON format) when deploying an app.
- Root Directory: Directory in your repository where the root of your Meteor app is.
- Pre Deploy Command: Command you run to install the app's dependencies, usually meteor npm install --production.
- Deploy Arguments: Arguments you can provide to your deploy command line.
- Environment Variables: You can specify the region where your app will be deployed.
With everything configured, just hit Deploy and the first version of your app will be deployed!
You need to have a GitHub/Bitbucket/GitLab repository with a Meteor project. The following Meteor versions are supported: 1.12.2, 2.0.1, 2.1.2, 2.2.4, 2.3.7, and any version from 2.4.1 to the latest. Otherwise, you will see an error in the logs of your app on Galaxy.
Deploy an existing app
On the app details page, you can click on the button Set up push to deploy.
The first two steps in this case are the same as deploying a new app. You will just have to connect your Git Provider, and then choose the repository. For the last step, make sure that everything is correct in the Deploy Options section. As the app is already deployed, all the other fields are already defined.
After configuring everything, if you need to edit it, you can click the Set up push to deploy button on the app details page.
Override Meteor Settings
Previously called Next auto deploy settings.
After configuring Push to Deploy for an app, you can find in Galaxy, on the settings tab, the title Override Meteor Settings. When you toggle the Override Settings and fill in the field below, on the next deploy, its content will be used instead of the settings.json file. After this deployment, if you change the settings.json file from the app and deploy it again, the JSON file from the app will still be ignored, and Galaxy will continue using the value from the field. To read the settings from the JSON file, you must untoggle the Override Settings.
Deploy Cost
The cost for deployments varies depending on which plan you are using on Galaxy.
- Free plan: No cost for deploys, but limited to 10 deploys per month.
- Essentials plan: Cost is the amount of time deploying x amount of GBs of memory x $0.08.
- Professional plan: Cost is the amount of time deploying x amount of GBs of memory x $0.11.
For example, if you spend 15 minutes on deployments using 3GBs of memory for an app in the Essential plan, the cost added to your invoice would be: 0.25h x 3GBs x $0.08 = $0.06.
If you want to use your own machines to build and deploy your apps, you can use the command-line.
FAQ
1. How to trigger new deploys?
After you finish setting up everything, every commit you do to the chosen branch will trigger a new deploy. Also, every time you save the configuration, a new deploy will be triggered.
2. Can I use the repository and branch for different apps?
Yes, you can. Be careful when setting up your apps to avoid deploying the wrong code to an app.
3. What happens if a new commit is pushed before the previous deploy is completed?
The previous deploy will be canceled, and the new one will start.
4. How can I cancel a deploy that is in progress?
You can't. For now, the only way a deploy is canceled is if a new commit arrives or if the deploy fails.
5. What does docker error 137 mean?
This error means there was an Out Of Memory error. To solve this, increase the amount of memory you use to deploy your app. You can do this on the third step of the Push to Deploy screen, in the Deploy options > Build Container RAM section.
Learn More
- Learn how to deploy applications with the command-line.
- Learn how to configure applications on Galaxy.
Updated on: 30/10/2024
Thank you!