# How is the community automating Fly infrastructure?

**URL:** <https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180>\
**Category:** General\
**Tags:** login-only\
**Created:** [October 30, 2023, 7:56pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180 "2023-10-30T19:56:55Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![kdevan](https://avatars.discourse-cdn.com/v4/letter/k/6a8cbe/32.png) [@kdevan](https://community.fly.io/u/kdevan)\
**Post date:** [October 30, 2023, 7:56pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/1 "2023-10-30T19:56:55Z")

</div>

I asked this question [here](https://github.com/fly-apps/terraform-provider-fly/issues/255) on the terraform provider repository but really my question is more general than that. Currently the terraform provider is not being maintained and is in a broken state where volumes don’t work. You can view the end of [this thread](https://community.fly.io/t/fresh-produce-volumes-endpoints-in-machines-api/14408/16) for context. I’m looking for a new method to maintain infrastructure.

I currently have about 15 machines running that all work together and need to be scaled up and down along with adding more machines but this is unreasonable for me to manage manually.

Is there another recommended way to automate fly infrastructure?

For anyone who’s automating many servers on Fly, how are you doing it?

---

<div class="post-metadata">

**Author:** ![charsleysa](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/charsleysa/32/16002_2.png) [@charsleysa](https://community.fly.io/u/charsleysa)\
**Post date:** [October 30, 2023, 10:57pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/2 "2023-10-30T22:57:00Z")

</div>

Hi @kdevan

What kind of services are you running?

For us, we use fly autostart/autostop for our dynamic services such as APIs and other HTTP services. This allows us to provision a large number of machines while only having to pay for them while they are running. For non-dynamic services these scale ups are manual but they rarely need scaling.

As for the management, we use Github action pipelines that automatically deploy updates for apps that don’t use volumes. For machines needing volumes this is still a manual process but luckily for our requirements these machines don’t change very often.

---

<div class="post-metadata">

**Author:** ![Alex21](https://avatars.discourse-cdn.com/v4/letter/a/5e9695/32.png) [@Alex21](https://community.fly.io/u/Alex21)\
**Post date:** [October 31, 2023, 5:04am UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/3 "2023-10-31T05:04:17Z")

</div>

I haven’t tried it myself so can’t vouch for it, but you might be interested in [GitHub - GiGurra/flycd](https://github.com/GiGurra/flycd).

---

<div class="post-metadata">

**Author:** ![pmbanugo](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/pmbanugo/32/24280_2.png) [@pmbanugo](https://community.fly.io/u/pmbanugo)\
**Post date:** [October 31, 2023, 11:01am UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/4 "2023-10-31T11:01:17Z")

</div>

I’m building [FlyCD](https://flycd.dev) ([https://flycd.dev](https://flycd.dev)) as a means to automate the deployment and releases for people that deploy Fly apps and need automation for preview apps and preview databases. FlyCD doesn’t do GitOps infrastructure as code automation. I don’t know of any tool that do not. I think you’d have to pick a CI/CD system and figure out how to use their Machine API or use the CLI to automate them yourself.

I think the person who manages the Terraform provider now works at Fly, I’m surprised you say it’s unmaintained.

---

<div class="post-metadata">

**Author:** ![matifali](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/matifali/32/12902_2.png) [@matifali](https://community.fly.io/u/matifali)\
**Post date:** [October 31, 2023, 5:29pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/5 "2023-10-31T17:29:08Z")

</div>

Fly recently dropped support for the terrafform provider which is sad. The current state makes it unusable if you want to use volumes. I guess you have to directly use the API.

---

<div class="post-metadata">

**Author:** ![pmbanugo](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/pmbanugo/32/24280_2.png) [@pmbanugo](https://community.fly.io/u/pmbanugo)\
**Post date:** [October 31, 2023, 6:11pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/6 "2023-10-31T18:11:22Z")

</div>

Oh I didn’t know they dropped support. Thanks for sharing

---

<div class="post-metadata">

**Author:** ![kdevan](https://avatars.discourse-cdn.com/v4/letter/k/6a8cbe/32.png) [@kdevan](https://community.fly.io/u/kdevan)\
**Post date:** [October 31, 2023, 7:47pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/7 "2023-10-31T19:47:51Z")

</div>

Thank you for the feedback. I’ve seen some really cool Github actions setups so I’ll dive into this a bit but almost all of my services use volumes so this may not be viable. Also, good to know that you’ve had a good experience using cli manually for scaling up and down along with autostart/autostop. I already do use quite a few bash scripts to run multiple cli commands so maybe i’ll just be continuing in that direction.

The services are things like database, search engine, api, node.js, object storage, reverse proxy, and so forth.

---

<div class="post-metadata">

**Author:** ![kdevan](https://avatars.discourse-cdn.com/v4/letter/k/6a8cbe/32.png) [@kdevan](https://community.fly.io/u/kdevan)\
**Post date:** [October 31, 2023, 7:49pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/8 "2023-10-31T19:49:57Z")

</div>

Amazing. This is awesome! Thank you for the feedback.

---

<div class="post-metadata">

**Author:** ![ben-io](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/ben-io/32/35648_2.png) [@ben-io](https://community.fly.io/u/ben-io)\
**Post date:** [October 31, 2023, 8:40pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/9 "2023-10-31T20:40:31Z")

</div>

> [@charsleysa](#):
>
> As for the management, we use Github action pipelines that automatically deploy updates for apps that don’t use volumes. For machines needing volumes this is still a manual process but luckily for our requirements these machines don’t change very often.

What’s blocking you from using Github actions for machines with volumes?

---

<div class="post-metadata">

**Author:** ![charsleysa](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/charsleysa/32/16002_2.png) [@charsleysa](https://community.fly.io/u/charsleysa)\
**Post date:** [October 31, 2023, 8:58pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/10 "2023-10-31T20:58:15Z")

</div>

I may have worded that paragraph a bit ambiguously. It’s not a case that we can use github actions to deploy updates to machines with volumes. It’s a case that we can’t use autostart/autostop for machines with volumes due to the nature of the apps we run.

Our main app with volumes is our CockroachDB cluster. We currently use manual deploys for updates to ensure that only 1 machine at a time is offline to minimize risk of a loss of quorum, especially since deployment management is done by the fly CLI on the client side and not a server-side service.

---

<div class="post-metadata">

**Author:** ![charsleysa](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/charsleysa/32/16002_2.png) [@charsleysa](https://community.fly.io/u/charsleysa)\
**Post date:** [October 31, 2023, 9:00pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/11 "2023-10-31T21:00:29Z")

</div>

> [@kdevan](#):
>
> The services are things like database, search engine, api, node.js, object storage, reverse proxy, and so forth.

I don’t have insight into how your apps function so this may be misguided but I would think that the API, nodejs, and reverse proxy services don’t need volumes and would be prime candidates for autostart/autostop with over-provisioning.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/fly1/original/3X/6/e/6e8955d00cb218e186ebbe3a6ab06fefdce15290.svg) [@system](https://community.fly.io/u/system)\
**Post date:** [November 7, 2023, 9:01pm UTC](https://community.fly.io/t/how-is-the-community-automating-fly-infrastructure/16180/12 "2023-11-07T21:01:25Z")

</div>

Closed on November 7, 2023, 9:01pm UTC

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