@kervnet/opencode-kiro-auth 1.6.0 → 1.6.2
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/dist/plugin/request.js
CHANGED
|
@@ -128,6 +128,9 @@ export function transformToCodeWhisperer(url, body, model, auth, think = false,
|
|
|
128
128
|
}
|
|
129
129
|
}
|
|
130
130
|
};
|
|
131
|
+
if (auth.profileArn) {
|
|
132
|
+
request.profileArn = auth.profileArn;
|
|
133
|
+
}
|
|
131
134
|
const toolUsesInHistory = history.flatMap((h) => h.assistantResponseMessage?.toolUses || []);
|
|
132
135
|
const allToolUseIdsInHistory = new Set(toolUsesInHistory.map((tu) => tu.toolUseId));
|
|
133
136
|
const finalCurTrs = [];
|
|
@@ -4,6 +4,16 @@ import * as logger from '../logger';
|
|
|
4
4
|
import { kiroDb } from '../storage/sqlite';
|
|
5
5
|
export async function syncIAMFromKiroCli() {
|
|
6
6
|
try {
|
|
7
|
+
// Check if AWS credentials are configured
|
|
8
|
+
const { existsSync } = await import('node:fs');
|
|
9
|
+
const { homedir } = await import('node:os');
|
|
10
|
+
const { join } = await import('node:path');
|
|
11
|
+
const awsConfigPath = join(homedir(), '.aws', 'config');
|
|
12
|
+
const awsCredsPath = join(homedir(), '.aws', 'credentials');
|
|
13
|
+
if (!existsSync(awsConfigPath) && !existsSync(awsCredsPath)) {
|
|
14
|
+
logger.debug('IAM sync: No AWS credentials configured, skipping IAM auth');
|
|
15
|
+
return;
|
|
16
|
+
}
|
|
7
17
|
const output = execSync('kiro-cli whoami', { encoding: 'utf-8', stdio: ['pipe', 'pipe', 'pipe'] });
|
|
8
18
|
const lines = output.split('\n').map(l => l.trim()).filter(Boolean);
|
|
9
19
|
let profileName;
|
package/package.json
CHANGED