Skip to content

Commit

Permalink
Update gh file content to handle base64 png in line with PR #2286
Browse files Browse the repository at this point in the history
  • Loading branch information
jayBana committed Jul 8, 2024
1 parent 2100bcd commit d756ffb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fast/extras/0-cicd-github/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ locals {
_repository_files = flatten([
for k, v in var.repositories : [
for f in concat(
[for f in fileset(path.module, "${v.populate_from}/*.png") : f],
[for f in fileset(path.module, "${v.populate_from}/*.svg") : f],
[for f in fileset(path.module, "${v.populate_from}/*.md") : f],
(v.populate_samples ? [for f in fileset(path.module, "${v.populate_from}/*.sample") : f] : []),
Expand Down Expand Up @@ -167,7 +168,7 @@ resource "github_repository_file" "default" {
"/source(\\s*)=\\s*\"../../../modules/([^/\"]+)\"/",
"source$1= \"git@github.com:${local.modules_repo}.git//${local.module_prefix}$2${local.modules_ref}\"" # "
)
: file(each.value.file)
: try(file(each.value.file), filebase64(each.value.file))
)
commit_message = "${var.commit_config.message} (${each.value.name})"
commit_author = var.commit_config.author
Expand Down

0 comments on commit d756ffb

Please sign in to comment.