File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -63,7 +63,8 @@ locals {
6363 dynamodb_table_name = " ${ var . cluster_name } -state"
6464 bastion_sg_name = " ${ var . cluster_name } -bastion-sg"
6565
66- unison_credentials = jsondecode (file (" ~/.local/share/unisonlanguage/credentials.json" ))
66+ unison_credentials_file = " ~/.local/share/unisonlanguage/credentials.json"
67+ unison_credentials = jsondecode (fileexists (local. unison_credentials_file ) ? file (local. unison_credentials_file ) : file (" /dev/null" ))
6768 unison_token = local. unison_credentials . credentials . default [" api.unison-lang.org" ]. tokens . access_token
6869}
6970
Original file line number Diff line number Diff line change @@ -33,7 +33,8 @@ locals {
3333 eks_cluster_name = " ${ var . cluster_name } "
3434 dynamodb_table_name = " ${ var . cluster_name } -state"
3535
36- unison_credentials = jsondecode (file (" ~/.local/share/unisonlanguage/credentials.json" ))
36+ unison_credentials_file = " ~/.local/share/unisonlanguage/credentials.json"
37+ unison_credentials = jsondecode (fileexists (local. unison_credentials_file ) ? file (local. unison_credentials_file ) : file (" /dev/null" ))
3738 unison_token = local. unison_credentials . credentials . default [" api.unison-lang.org" ]. tokens . access_token
3839}
3940
You can’t perform that action at this time.
0 commit comments