base deployment decision on packaged zip
This commit is contained in:
parent
12c09b291d
commit
7eadd2e6e5
|
@ -140,7 +140,7 @@ pub fn configureBuild(b: *std.build.Builder, exe: *std.Build.Step.Compile) !void
|
|||
// Amazon Linux 2 is the only arm64 supported option
|
||||
// TODO: This should determine compilation target and use x86_64 if needed
|
||||
const not_found = "aws lambda create-function --architectures arm64 --runtime provided.al2 --function-name {s} --zip-file fileb://{s} --handler not_applicable {s} && touch {s}";
|
||||
const not_found_fmt = try std.fmt.allocPrint(b.allocator, not_found, .{ function_name, function_zip, iam_role, function_name_file });
|
||||
const not_found_fmt = try std.fmt.allocPrint(b.allocator, not_found, .{ function_name, function_zip, iam_role_param, function_name_file });
|
||||
defer b.allocator.free(not_found_fmt);
|
||||
const found = "aws lambda update-function-code --function-name {s} --zip-file fileb://{s} && touch {s}";
|
||||
const found_fmt = try std.fmt.allocPrint(b.allocator, found, .{ function_name, function_zip, function_name_file });
|
||||
|
@ -156,7 +156,7 @@ pub fn configureBuild(b: *std.build.Builder, exe: *std.Build.Step.Compile) !void
|
|||
}
|
||||
const cmd = try std.fmt.allocPrint(b.allocator, ifstatement, .{
|
||||
function_name_file,
|
||||
std.fs.path.dirname(exe.root_src.?.path).?,
|
||||
b.getInstallPath(.bin, "function.zip"),
|
||||
function_name_file,
|
||||
function_name,
|
||||
not_found_fmt,
|
||||
|
|
Loading…
Reference in New Issue
Block a user