Skip to content

armgit / qm

Public Imported from GitHub
0

Multiplayer agent harness for work.

Fix AWS production deployment blockers (#163)

Joshua France291faf194c1d
diff --git a/aws/microvm-agent/Dockerfile b/aws/microvm-agent/Dockerfile
index 5a354d85f..bafeca463 100644
--- a/aws/microvm-agent/Dockerfile
+++ b/aws/microvm-agent/Dockerfile
@@ -14,7 +14,7 @@ RUN dnf install -y \
RUN curl -fsSL https://cli.github.com/packages/rpm/gh-cli.repo \
-o /etc/yum.repos.d/gh-cli.repo \
- && dnf install -y gh-2.96.0-1 \
+ && dnf install -y gh-2.97.0-1 \
&& dnf clean all \
&& gh --version
diff --git a/cli/package-lock.json b/cli/package-lock.json
index a1e9d4aae..6a1229211 100644
--- a/cli/package-lock.json
+++ b/cli/package-lock.json
@@ -1,12 +1,12 @@
{
"name": "@yc-software/qm",
- "version": "0.1.4",
+ "version": "0.1.5",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "@yc-software/qm",
- "version": "0.1.4",
+ "version": "0.1.5",
"license": "MIT",
"bin": {
"qm": "dist/bin/qm.js"
diff --git a/cli/package.json b/cli/package.json
index 6961d06f3..d7349677a 100644
--- a/cli/package.json
+++ b/cli/package.json
@@ -1,6 +1,6 @@
{
"name": "@yc-software/qm",
- "version": "0.1.4",
+ "version": "0.1.5",
"license": "MIT",
"description": "Control-plane CLI for portable QM deployments on Docker, Fly, and AWS.",
"type": "module",
diff --git a/cli/templates/aws/main.tf b/cli/templates/aws/main.tf
index b68f865b7..ea83f5e2c 100644
--- a/cli/templates/aws/main.tf
+++ b/cli/templates/aws/main.tf
@@ -569,12 +569,6 @@ resource "aws_s3_bucket_lifecycle_configuration" "objects" {
expired_object_delete_marker = true
}
- # The core writes this same rule id via ensureExpiry, with the same 1 day and this same clause,
- # so whichever applies last leaves an identical config instead of the two stripping each other.
- # Parts from an upload that died mid-stream are invisible to ListObjects; only this reaps them.
- abort_incomplete_multipart_upload {
- days_after_initiation = 1
- }
}
rule {
@@ -588,6 +582,11 @@ resource "aws_s3_bucket_lifecycle_configuration" "objects" {
expiration {
days = 1
}
+
+ # Keep this identical to the rule written by the core's ensureExpiry.
+ abort_incomplete_multipart_upload {
+ days_after_initiation = 1
+ }
}
}
diff --git a/cli/templates/aws/microvm-agent/Dockerfile b/cli/templates/aws/microvm-agent/Dockerfile
index 5a354d85f..bafeca463 100644
--- a/cli/templates/aws/microvm-agent/Dockerfile
+++ b/cli/templates/aws/microvm-agent/Dockerfile
@@ -14,7 +14,7 @@ RUN dnf install -y \
RUN curl -fsSL https://cli.github.com/packages/rpm/gh-cli.repo \
-o /etc/yum.repos.d/gh-cli.repo \
- && dnf install -y gh-2.96.0-1 \
+ && dnf install -y gh-2.97.0-1 \
&& dnf clean all \
&& gh --version
diff --git a/cli/test/terraform.test.ts b/cli/test/terraform.test.ts
index 229be6b7c..bb52ea455 100644
--- a/cli/test/terraform.test.ts
+++ b/cli/test/terraform.test.ts
@@ -359,7 +359,10 @@ test("AWS module provisions durable encrypted object storage and configurable sa
assert.match(mainTf, /expiration\s*\{\s*expired_object_delete_marker\s*= true\s*\}/);
assert.match(mainTf, /"s3:GetObject", "s3:PutObject", "s3:DeleteObject", "s3:AbortMultipartUpload"/);
assert.match(mainTf, /"s3:ListBucketMultipartUploads"/);
- assert.match(mainTf, /abort_incomplete_multipart_upload\s*\{\s*days_after_initiation\s*= 1\s*\}/);
+ assert.match(
+ mainTf,
+ /id\s*= "qm-transfer-expiry"[\s\S]*?abort_incomplete_multipart_upload\s*\{\s*days_after_initiation\s*= 1\s*\}/,
+ );
assert.match(mainTf, /backup_retention_period\s*= var\.db_backup_retention_days/);
assert.match(mainTf, /multi_az\s*= var\.db_multi_az/);
assert.match(mainTf, /skip_final_snapshot\s*= var\.db_skip_final_snapshot/);