Fix Examples (#11)

This commit is contained in:
Robert Fairburn authored and GitHub committed 2025-02-20 18:20:55 -06:00
1 parent 6ff853ed7b
commit d2ba0fec3f
5 files changed
+57 -18

No files matched your search

+5 -5
View File
@@ -18,7 +18,7 @@ Due to Terraform issues, this code requires 3 applies "from scratch":
6. `terraform apply`
7. If enabling mdm do the following:
- Record the KMS key from step 5 output.
- Use `fleetctl` to obtain all of the mdm certs. Use https://fleetdm.com/docs/using-fleet/mdm-macos-setup#apple-push-notification-service-apns and https://fleetdm.com/docs/using-fleet/mdm-setup#apple-business-manager-abm for reference.
- Use `fleetctl` to obtain all of the mdm certs. Use https://fleetdm.com/docs/using-fleet/mdm-setup#apple-push-notification-service-apns and https://fleetdm.com/docs/using-fleet/mdm-setup#apple-business-manager-abm for reference.
- Place the certificates in the `resources` folder with the following names based upon their function:
```
scep.crt
@@ -58,10 +58,10 @@ This will encrypt all of the mdm secrets and add the .encrypted extension to the
| Name | Source | Version |
|------|--------|---------|
| <a name="module_acm"></a> [acm](#module\_acm) | terraform-aws-modules/acm/aws | 4.3.1 |
| <a name="module_firehose-logging"></a> [firehose-logging](#module\_firehose-logging) | github.com/fleetdm/fleet-terraform//addons/logging-destination-firehose | tf-mod-addon-logging-destination-firehose-v1.1.0 |
| <a name="module_fleet"></a> [fleet](#module\_fleet) | github.com/fleetdm/fleet-terraform/ | tf-mod-root-v1.7.3 |
| <a name="module_migrations"></a> [migrations](#module\_migrations) | github.com/fleetdm/fleet-terraform//addons/migrations | tf-mod-addon-migrations-v2.0.0 |
| <a name="module_osquery-carve"></a> [osquery-carve](#module\_osquery-carve) | github.com/fleetdm/fleet-terraform//addons/osquery-carve | tf-mod-addon-osquery-carve-v1.0.1 |
| <a name="module_firehose-logging"></a> [firehose-logging](#module\_firehose-logging) | github.com/fleetdm/fleet-terraform/addons/logging-destination-firehose | tf-mod-addon-logging-destination-firehose-v1.1.1 |
| <a name="module_fleet"></a> [fleet](#module\_fleet) | github.com/fleetdm/fleet-terraform | tf-mod-root-v1.12.0 |
| <a name="module_migrations"></a> [migrations](#module\_migrations) | github.com/fleetdm/fleet-terraform/addons/migrations | tf-mod-addon-migrations-v2.0.1 |
| <a name="module_osquery-carve"></a> [osquery-carve](#module\_osquery-carve) | github.com/fleetdm/fleet-terraform/addons/osquery-carve | tf-mod-addon-osquery-carve-v1.1.0 |
## Resources
+5 -5
View File
@@ -50,7 +50,7 @@ locals {
}
module "fleet" {
source = "github.com/fleetdm/fleet-terraform/?ref=tf-mod-root-v1.11.1"
source = "github.com/fleetdm/fleet-terraform?ref=tf-mod-root-v1.12.0"
certificate_arn = module.acm.acm_certificate_arn
vpc = {
@@ -118,7 +118,7 @@ module "fleet" {
# doesn't directly support all the features required. the aws cli is invoked via a null-resource.
module "migrations" {
source = "github.com/fleetdm/fleet-terraform//addons/migrations?ref=tf-mod-addon-migrations-v2.0.1"
source = "github.com/fleetdm/fleet-terraform/addons/migrations?ref=tf-mod-addon-migrations-v2.0.1"
ecs_cluster = module.fleet.byo-vpc.byo-db.byo-ecs.service.cluster
task_definition = module.fleet.byo-vpc.byo-db.byo-ecs.task_definition.family
task_definition_revision = module.fleet.byo-vpc.byo-db.byo-ecs.task_definition.revision
@@ -131,14 +131,14 @@ module "migrations" {
module "osquery-carve" {
# The carve bucket also stores software.
source = "github.com/fleetdm/fleet-terraform//addons/osquery-carve?ref=tf-mod-addon-osquery-carve-v1.1.0"
source = "github.com/fleetdm/fleet-terraform/addons/osquery-carve?ref=tf-mod-addon-osquery-carve-v1.1.0"
osquery_carve_s3_bucket = {
name = local.osquery_carve_bucket_name
}
}
module "firehose-logging" {
source = "github.com/fleetdm/fleet-terraform//addons/logging-destination-firehose?ref=tf-mod-addon-logging-destination-firehose-v1.1.1"
source = "github.com/fleetdm/fleet-terraform/addons/logging-destination-firehose?ref=tf-mod-addon-logging-destination-firehose-v1.1.1"
osquery_results_s3_bucket = {
name = local.osquery_results_bucket_name
}
@@ -161,7 +161,7 @@ module "firehose-logging" {
# module "mdm" {
# source = "github.com/fleetdm/fleet-terraform//addons/mdm?ref=tf-mod-addon-mdm-v2.0.0"
# source = "github.com/fleetdm/fleet-terraform/addons/mdm?ref=tf-mod-addon-mdm-v2.0.0"
# # Set apn_secret_name = null if not using mac mdm
# apn_secret_name = "fleet-apn"
# scep_secret_name = "fleet-scep"
+7 -7
View File
@@ -6,13 +6,13 @@
locals {
mdm_resource_path = "${path.module}/resources"
scep_cert = "${local.mdm_resource_path}/scep.crt.encrypted"
scep_key = "${local.mdm_resource_path}/scep.key.encrypted"
apns_cert = "${local.mdm_resource_path}/apns.crt.encrypted"
apns_key = "${local.mdm_resource_path}/apns.key.encrypted"
abm_cert = "${local.mdm_resource_path}/abm.crt.encrypted"
abm_key = "${local.mdm_resource_path}/abm.key.encrypted"
abm_token = "${local.mdm_resource_path}/abm_token.p7m.encrypted"
scep_cert = "${local.mdm_resource_path}/scep.crt.encrypted"
scep_key = "${local.mdm_resource_path}/scep.key.encrypted"
apns_cert = "${local.mdm_resource_path}/apns.crt.encrypted"
apns_key = "${local.mdm_resource_path}/apns.key.encrypted"
abm_cert = "${local.mdm_resource_path}/abm.crt.encrypted"
abm_key = "${local.mdm_resource_path}/abm.key.encrypted"
abm_token = "${local.mdm_resource_path}/abm_token.p7m.encrypted"
}
# To ease the process of encrypting and decrypting secrets, see