Skip to content

Commit 2d92ab9

Browse files
rootroot
authored andcommitted
fixed conflicts
2 parents 6b814cb + 954e404 commit 2d92ab9

File tree

3 files changed

+48
-6
lines changed

3 files changed

+48
-6
lines changed

.gitignore

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
# Local .terraform directories
1+
# Local hidden directories
22
**/.terraform/*
3+
**/.backup/*
34

4-
# .tfstate files
5-
**/*.tf*
5+
# Local .tfstate files
6+
*.tfstate
7+
*.tfstate.*
8+
9+
# Zipped google function
10+
google_function/demo.*

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -217,8 +217,8 @@ terrahub graph
217217
Your output should be similar to the one below:
218218
```
219219
Project: demo-terraform-automation-google
220-
└─ google_storage_7b3c5d2c [path: ./google_storage_7b3c5d2c]
221-
└─ google_function_7b3c5d2c [path: ./google_function_7b3c5d2c]
220+
└─ google_storage [path: ./google_storage]
221+
└─ google_function [path: ./google_function]
222222
```
223223

224224

google_function/.terrahub.yml

Lines changed: 38 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ component:
33
mapping:
44
- .
55
dependsOn:
6-
- ../demo_storage_bucket
6+
- ../google_storage
77
template:
88
terraform:
99
backend:
@@ -23,9 +23,15 @@ component:
2323
source: ./demo.zip
2424
google_cloudfunctions_function:
2525
google_function:
26+
<<<<<<< HEAD:google_function/.terrahub.yml
2627
depends_on:
2728
- google_storage_bucket_object.google_storage_object
2829
name: 'demofunction${local.project["code"]}'
30+
=======
31+
name: 'demofunction${local.project["code"]}'
32+
depends_on:
33+
- google_storage_bucket_object.google_storage_object
34+
>>>>>>> 954e40474032055d4b4f929cfdbe7991e50c8e39:google_function/.terrahub.yml
2935
region: us-central1
3036
runtime: nodejs8
3137
description: My demo function
@@ -35,6 +41,24 @@ component:
3541
trigger_http: true
3642
timeout: 60
3743
entry_point: helloGET
44+
<<<<<<< HEAD:google_function/.terrahub.yml
45+
=======
46+
google_storage_bucket_object:
47+
google_storage_object:
48+
name: demo.zip
49+
bucket: '${data.terraform_remote_state.storage.thub_id}'
50+
source: ./demo.zip
51+
terraform:
52+
backend:
53+
local:
54+
path: /tmp/.terrahub/local_backend/google_function/terraform.tfstate
55+
data:
56+
terraform_remote_state:
57+
storage:
58+
backend: local
59+
config:
60+
path: /tmp/.terrahub/local_backend/google_storage/terraform.tfstate
61+
>>>>>>> 954e40474032055d4b4f929cfdbe7991e50c8e39:google_function/.terrahub.yml
3862
output:
3963
id:
4064
value: '${google_cloudfunctions_function.google_function.id}'
@@ -64,7 +88,20 @@ build:
6488
build:
6589
commands:
6690
- 'echo "BUILD: Running build step"'
91+
<<<<<<< HEAD:google_function/.terrahub.yml
6792
- ./scripts/build.sh $COMPONENT_NAME $OBJECT_NAME $THUB_BUCKET_KEY/
93+
=======
94+
- >-
95+
if [ "$(head -n 1 "$THUB_FUNCTION_TXT")" != "$(stat -c %y
96+
"${THUB_BUILD_PATH}/index.js")" ]; then zip -j ${THUB_FUNCTION_ZIP}
97+
${THUB_BUILD_PATH}/index.js; fi
98+
- >-
99+
if [ "$(head -n 1 "$THUB_FUNCTION_TXT")" != "$(stat -c %y
100+
"${THUB_BUILD_PATH}/index.js")" ]; then terrahub configure -i
101+
google_function -c
102+
component.template.resource.google_storage_bucket_object.google_storage_object.name=$(date
103+
+%s).zip; fi
104+
>>>>>>> 954e40474032055d4b4f929cfdbe7991e50c8e39:google_function/.terrahub.yml
68105
finally:
69106
- 'echo "BUILD: build step successful"'
70107
post_build:

0 commit comments

Comments
 (0)