Skip to content

Commit 8a12098

Browse files
authored
VACMS-16237: Replace s3 address for assets. (#16777)
* VACMS-16237: Replace s3 address for assets. * Subtract a line. * Try a local build. * So much for KISS.
1 parent e427a1c commit 8a12098

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

scripts/web-build.sh

+8-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ touch ./.buildlock
1717
build_type="vagovdev"
1818
web_path="./web"
1919
build_path="${web_path}/build/${build_type}"
20-
assets_base_url="https://dev-va-gov-assets\.s3-us-gov-west-1\.amazonaws\.com"
2120
rm -rf "${build_path}"
2221

2322
pushd "${web_path}"
@@ -35,11 +34,19 @@ yarn build \
3534
popd
3635

3736
echo "Replacing s3 address with local in generated files."
37+
assets_base_url="https://dev-va-gov-assets\.s3-us-gov-west-1\.amazonaws\.com"
3838
find \
3939
"${build_path}/generated" \
4040
-type f \
4141
-exec sed -i "s#${assets_base_url}##g" {} \+;
4242

43+
echo "Replacing s3 address with local in built content."
44+
dev_base_url="https://s3-us-gov-west-1\.amazonaws\.com/content\.dev\.va\.gov"
45+
find \
46+
"${build_path}" \
47+
-type f \
48+
-exec sed -i -e "s#${dev_base_url}##g" {} \+;
49+
4350
rm ./.buildlock
4451

4552
popd > /dev/null

0 commit comments

Comments
 (0)