@@ -31,6 +31,9 @@ GITHUB_TOKEN ?= ""
31
31
FULL_BUILD ?= false
32
32
CONFIGURATION_FILE ?= "./local/bin/py/build/configurations/pull_config_preview.yaml"
33
33
34
+ # Set default S3 path for websites sources data
35
+ FF_S3_PATH ?= "staging"
36
+
34
37
help :
35
38
@perl -nle' print $& if m{^[a-zA-Z_-]+:.*?## .*$$}' $(MAKEFILE_LIST ) | sort | awk ' BEGIN {FS = ":.*?## "}; {printf "\033[36m%-25s\033[0m %s\n", $$1, $$2}'
36
39
@@ -129,10 +132,16 @@ node_modules: package.json yarn.lock
129
132
dependencies : clean
130
133
make hugpython all-examples update_pre_build node_modules build-cdocs websites_sources_data build-llms-txt
131
134
132
- # Download files from S3 bucket and add them to the file system
135
+ # Download files from S3 bucket and add them to the file system.
136
+ # Preview S3 content locally: add FF_S3_PATH env var when executing appropriate Make targets
137
+ # e.g. make start-sources FF_S3_PATH=<websites-sources feature branch>
133
138
websites_sources_data : hugpython
134
- @echo " Downloading data from websites-sources S3 bucket..."
135
- @. hugpython/bin/activate && python3 ./local/bin/py/build/get_websites_sources_data.py
139
+ @echo " Removing _vendor directory..."
140
+ rm -rf _vendor
141
+ @echo " Downloading fresh data from websites-sources S3 bucket..."
142
+ @. hugpython/bin/activate && \
143
+ export FF_S3_PATH=${FF_S3_PATH} && \
144
+ python3 ./local/bin/py/build/get_websites_sources_data.py
136
145
137
146
integrations_data/extracted/vector :
138
147
$(call source_repo,vector,https://github.com/vectordotdev/vector.git,master,true,website/)
@@ -164,18 +173,18 @@ config:
164
173
envsubst ' $$CI_COMMIT_REF_NAME' < " config/$( CI_ENVIRONMENT_NAME) /params.yaml" | sponge " config/$( CI_ENVIRONMENT_NAME) /params.yaml" ; \
165
174
echo -e " \nbranch: ${CI_COMMIT_REF_NAME} " >> config/$(CI_ENVIRONMENT_NAME ) /params.yaml;
166
175
167
- # Automatically download the latest module from websites-sources repo
168
- update_websites_sources_module :
169
- node_modules/hugo-bin/vendor/hugo mod get github.com/DataDog/websites-sources@main
170
- node_modules/hugo-bin/vendor/hugo mod clean
171
- node_modules/hugo-bin/vendor/hugo mod tidy
172
- cat go.mod
173
- @if [ -n " $( CI_COMMIT_REF_NAME) " ]; then \
174
- echo " In ci, vendoring integrations pages for placeholder generation" ; \
175
- node_modules/hugo-bin/vendor/hugo mod vendor; \
176
- cp -rpv _vendor/github.com/DataDog/websites-sources/content/en/integrations/. content/en/integrations/; \
177
- rm -rf _vendor; \
178
- fi
176
+ # # Automatically download the latest module from websites-sources repo
177
+ # update_websites_sources_module:
178
+ # node_modules/hugo-bin/vendor/hugo mod get github.com/DataDog/websites-sources@main
179
+ # node_modules/hugo-bin/vendor/hugo mod clean
180
+ # node_modules/hugo-bin/vendor/hugo mod tidy
181
+ # cat go.mod
182
+ # @if [ -n "$(CI_COMMIT_REF_NAME)" ]; then \
183
+ # echo "In ci, vendoring integrations pages for placeholder generation"; \
184
+ # node_modules/hugo-bin/vendor/hugo mod vendor; \
185
+ # cp -rpv _vendor/github.com/DataDog/websites-sources/content/en/integrations/. content/en/integrations/; \
186
+ # rm -rf _vendor; \
187
+ # fi
179
188
180
189
# ######################################################################################################################
181
190
# API Code Examples
0 commit comments