@fishawack/lab-env 5.7.0-beta.10 → 5.7.0-beta.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,16 @@
1
1
  ## Changelog
2
2
 
3
+ ### 5.7.0-beta.11 (2026-08-24)
4
+
5
+ #### Bug Fixes
6
+
7
+ * force html to never cache via server headers ([90a6a5b](https://bitbucket.org/fishawackdigital/lab-env/commits/90a6a5b3c62321b2a44417ae01380442fa42e2f3))
8
+ * prov mysql 8.4.10 on new sites ([c4fd6ea](https://bitbucket.org/fishawackdigital/lab-env/commits/c4fd6ea4422451132552c5cc0b3ef0590a6b6c97))
9
+ * removed deprecated flag from mysql start command for drupal and wordpress ([b7853d6](https://bitbucket.org/fishawackdigital/lab-env/commits/b7853d6e67ee5dba0e4c9421ad4f7497ccb84584))
10
+ * support mysql 8.4 param groups with ability to still restore older versions ([e3307dd](https://bitbucket.org/fishawackdigital/lab-env/commits/e3307ddf542781f4cfc65258f3ffc0ff30d29279))
11
+ * upgrade mysql version to 8.4 across all builds ([b33189b](https://bitbucket.org/fishawackdigital/lab-env/commits/b33189bf3e55a161501f29baa98107f1eb16edd9))
12
+ * use correct creds on pr open post release ([d560ef8](https://bitbucket.org/fishawackdigital/lab-env/commits/d560ef84c0ebd99a3ad1ffc457a9a6758fa46c06))
13
+
3
14
  ### 5.7.0-beta.10 (2026-08-24)
4
15
 
5
16
  #### Build Updates
package/_Ai/lab-env-@.md CHANGED
@@ -58,7 +58,7 @@ The core container runs on ports:
58
58
  ```yaml
59
59
  services:
60
60
  core: # Frontend builds, deployments, Node.js
61
- mysql: # Database (MySQL 8.0.32)
61
+ mysql: # Database (MySQL 8.4)
62
62
  nginx: # Web server
63
63
  php: # PHP-FPM application server
64
64
  redis: # Caching and sessions
@@ -72,7 +72,7 @@ services:
72
72
  ```yaml
73
73
  services:
74
74
  core: # Frontend builds, deployments, Node.js
75
- mysql: # Database (MySQL 8.0.32)
75
+ mysql: # Database (MySQL 8.4)
76
76
  apache: # Web server with PHP
77
77
  php: # PHP-FPM for additional processing
78
78
  ```
@@ -84,7 +84,7 @@ services:
84
84
  ```yaml
85
85
  services:
86
86
  core: # Frontend builds, deployments, Node.js
87
- mysql: # Database (MySQL 8.0.32)
87
+ mysql: # Database (MySQL 8.4)
88
88
  apache: # Web server with PHP
89
89
  php: # PHP-FPM application server
90
90
  ```
@@ -21,7 +21,7 @@ git commit -m "build($BITBUCKET_REPO_SLUG): Bumped $BITBUCKET_REPO_SLUG"
21
21
  git push origin "$BITBUCKET_REPO_SLUG-$BITBUCKET_COMMIT"
22
22
 
23
23
  curl https://api.bitbucket.org/2.0/repositories/fishawackdigital/aws-runner/pullrequests \
24
- -u $GIT_CREDENTIALS \
24
+ --header "Authorization: Bearer $BITBUCKET_ACCESS_TOKEN" \
25
25
  --header 'Content-Type: application/json' \
26
26
  --data "{
27
27
  \"title\": \"Bumped $BITBUCKET_REPO_SLUG\",
@@ -1,6 +1,6 @@
1
1
  services:
2
2
  mysql:
3
- image: mysql:8.0.32
3
+ image: mysql:8.4
4
4
  networks:
5
5
  - default
6
6
  environment:
@@ -24,5 +24,16 @@ function handler(event) {
24
24
  headers["x-frame-options"] = { value: "sameorigin" };
25
25
  }
26
26
 
27
+ // Ensure html files aren't cached by browser
28
+ var contentType =
29
+ (headers["content-type"] && headers["content-type"].value) || "";
30
+ var isHtml = contentType.includes("text/html");
31
+
32
+ if (isHtml) {
33
+ headers["cache-control"] = {
34
+ value: "no-cache, no-store, must-revalidate",
35
+ };
36
+ }
37
+
27
38
  return response;
28
39
  }
@@ -63,7 +63,7 @@ module.exports.createRDSInstance = async (
63
63
  DBInstanceIdentifier: name,
64
64
  DBInstanceClass: "db.t3.small",
65
65
  Engine: "mysql",
66
- EngineVersion: "8.0.43",
66
+ EngineVersion: "8.4.10",
67
67
  MasterUsername: "ebroot",
68
68
  MasterUserPassword: password,
69
69
  AllocatedStorage: 5,
@@ -71,7 +71,7 @@ module.exports.createRDSInstance = async (
71
71
  PubliclyAccessible: false,
72
72
  BackupRetentionPeriod: 7,
73
73
  DBName: "ebdb",
74
- DBParameterGroupName: "lab-env-mysql80-ssl-required",
74
+ DBParameterGroupName: SSL_PARAMETER_GROUPS["8.4"].name,
75
75
  DBSubnetGroupName: subnetGroupName,
76
76
  VpcSecurityGroupIds: [securityGroupId],
77
77
  Tags: [
@@ -189,6 +189,20 @@ module.exports.restoreRDSInstanceFromSnapshot = async (
189
189
  tags = [],
190
190
  subnetGroupName,
191
191
  ) => {
192
+ // Snapshots keep the engine version of their source instance, so the restored
193
+ // instance must use a parameter group from the matching mysql family.
194
+ const [{ EngineVersion }] = (
195
+ await getClient().send(
196
+ new DescribeDBSnapshotsCommand({
197
+ DBSnapshotIdentifier: snapshotId,
198
+ }),
199
+ )
200
+ ).DBSnapshots;
201
+
202
+ const parameterGroupName = await module.exports.ensureSSLParameterGroup(
203
+ getEngineMajorVersion(EngineVersion),
204
+ );
205
+
192
206
  let res = await Spinner.prototype.simple(
193
207
  `Restoring RDS instance ${name} from snapshot ${snapshotId}`,
194
208
  () => {
@@ -198,7 +212,7 @@ module.exports.restoreRDSInstanceFromSnapshot = async (
198
212
  DBSnapshotIdentifier: snapshotId,
199
213
  DBInstanceClass: "db.t3.small",
200
214
  PubliclyAccessible: false,
201
- DBParameterGroupName: "lab-env-mysql80-ssl-required",
215
+ DBParameterGroupName: parameterGroupName,
202
216
  DBSubnetGroupName: subnetGroupName,
203
217
  VpcSecurityGroupIds: [securityGroupId],
204
218
  Tags: [
@@ -227,9 +241,30 @@ module.exports.modifyRDSPassword = async (name, password) => {
227
241
  );
228
242
  };
229
243
 
230
- const SSL_PARAMETER_GROUP = "lab-env-mysql80-ssl-required";
244
+ // Parameter groups are versioned per mysql family; snapshots older than the
245
+ // current default (8.4) still need their original family's group to restore.
246
+ const SSL_PARAMETER_GROUPS = {
247
+ "8.0": { name: "lab-env-mysql80-ssl-required", family: "mysql8.0" },
248
+ 8.4: { name: "lab-env-mysql84-ssl-required", family: "mysql8.4" },
249
+ };
250
+ const DEFAULT_ENGINE_MAJOR_VERSION = "8.4";
251
+
252
+ const getEngineMajorVersion = (engineVersion) =>
253
+ engineVersion.split(".").slice(0, 2).join(".");
254
+
255
+ module.exports.ensureSSLParameterGroup = async (
256
+ engineMajorVersion = DEFAULT_ENGINE_MAJOR_VERSION,
257
+ ) => {
258
+ const group = SSL_PARAMETER_GROUPS[engineMajorVersion];
259
+
260
+ if (!group) {
261
+ throw new Error(
262
+ `No managed SSL parameter group configured for MySQL ${engineMajorVersion}`,
263
+ );
264
+ }
265
+
266
+ const { name: SSL_PARAMETER_GROUP, family } = group;
231
267
 
232
- module.exports.ensureSSLParameterGroup = async () => {
233
268
  try {
234
269
  await getClient().send(
235
270
  new DescribeDBParameterGroupsCommand({
@@ -243,7 +278,7 @@ module.exports.ensureSSLParameterGroup = async () => {
243
278
  return getClient().send(
244
279
  new CreateDBParameterGroupCommand({
245
280
  DBParameterGroupName: SSL_PARAMETER_GROUP,
246
- DBParameterGroupFamily: "mysql8.0",
281
+ DBParameterGroupFamily: family,
247
282
  Description:
248
283
  "lab-env managed parameter group requiring SSL connections",
249
284
  }),
@@ -269,4 +304,6 @@ module.exports.ensureSSLParameterGroup = async () => {
269
304
  },
270
305
  );
271
306
  }
307
+
308
+ return SSL_PARAMETER_GROUP;
272
309
  };
@@ -1,6 +1,6 @@
1
1
  services:
2
2
  mysql:
3
- image: mysql:8.0.32
3
+ image: mysql:8.4
4
4
  networks:
5
5
  - default
6
6
  environment:
@@ -14,7 +14,6 @@ services:
14
14
  - mysql:/var/lib/mysql
15
15
  security_opt:
16
16
  - seccomp:unconfined
17
- command: --default-authentication-plugin=mysql_native_password
18
17
  apache:
19
18
  build:
20
19
  context: $DIRNAME/drupal/9/apache/
@@ -1,6 +1,6 @@
1
1
  services:
2
2
  mysql:
3
- image: mysql:8.0.32
3
+ image: mysql:8.4
4
4
  networks:
5
5
  - default
6
6
  environment:
@@ -1,6 +1,6 @@
1
1
  services:
2
2
  mysql:
3
- image: mysql:8.0.32
3
+ image: mysql:8.4
4
4
  networks:
5
5
  - default
6
6
  environment:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fishawack/lab-env",
3
- "version": "5.7.0-beta.10",
3
+ "version": "5.7.0-beta.11",
4
4
  "description": "Docker manager for FW",
5
5
  "main": "cli.js",
6
6
  "scripts": {
@@ -1,6 +1,6 @@
1
1
  services:
2
2
  mysql:
3
- image: mysql:8.0.32
3
+ image: mysql:8.4
4
4
  networks:
5
5
  - default
6
6
  environment:
@@ -14,7 +14,6 @@ services:
14
14
  - mysql:/var/lib/mysql
15
15
  security_opt:
16
16
  - seccomp:unconfined
17
- command: --default-authentication-plugin=mysql_native_password
18
17
  apache:
19
18
  build:
20
19
  context: $DIRNAME/wordpress/1/apache/