dank-ai 1.0.27 → 1.0.28

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.
@@ -1149,14 +1149,21 @@ class DockerManager {
1149
1149
 
1150
1150
  try {
1151
1151
  const buildContext = await this.createAgentBuildContext(agent);
1152
-
1153
- const stream = await this.docker.buildImage(buildContext, {
1154
- t: imageName,
1155
- dockerfile: "Dockerfile",
1156
- nocache: options.rebuild || options.noCache || false,
1157
- });
1158
-
1159
- await this.followBuildProgress(stream, `Agent ${agent.name} build`);
1152
+ const dockerCmd = await this.resolveDockerCommand();
1153
+
1154
+ const buildCommand = [
1155
+ dockerCmd,
1156
+ 'buildx',
1157
+ 'build',
1158
+ '--platform', 'linux/amd64,linux/arm64',
1159
+ '--tag', imageName,
1160
+ '--file', path.join(buildContext, 'Dockerfile'),
1161
+ '--load',
1162
+ ...(options.rebuild || options.noCache ? ['--no-cache'] : []),
1163
+ buildContext
1164
+ ].join(' ');
1165
+
1166
+ await this.runCommand(buildCommand, `Agent ${agent.name} build`);
1160
1167
 
1161
1168
  this.logger.info(`Agent image '${imageName}' built successfully`);
1162
1169
 
@@ -1214,17 +1221,21 @@ class DockerManager {
1214
1221
 
1215
1222
  try {
1216
1223
  const buildContext = await this.createAgentBuildContext(agent);
1217
-
1218
- const stream = await this.docker.buildImage(buildContext, {
1219
- t: imageName,
1220
- dockerfile: "Dockerfile",
1221
- nocache: force,
1222
- });
1223
-
1224
- await this.followBuildProgress(
1225
- stream,
1226
- `Production build for ${agent.name}`
1227
- );
1224
+ const dockerCmd = await this.resolveDockerCommand();
1225
+
1226
+ const buildCommand = [
1227
+ dockerCmd,
1228
+ 'buildx',
1229
+ 'build',
1230
+ '--platform', 'linux/amd64,linux/arm64',
1231
+ '--tag', imageName,
1232
+ '--file', path.join(buildContext, 'Dockerfile'),
1233
+ '--load',
1234
+ ...(force ? ['--no-cache'] : []),
1235
+ buildContext
1236
+ ].join(' ');
1237
+
1238
+ await this.runCommand(buildCommand, `Production build for ${agent.name}`);
1228
1239
 
1229
1240
  this.logger.info(`Production image '${imageName}' built successfully`);
1230
1241
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dank-ai",
3
- "version": "1.0.27",
3
+ "version": "1.0.28",
4
4
  "description": "Dank Agent Service - Docker-based AI agent orchestration platform",
5
5
  "main": "lib/index.js",
6
6
  "exports": {