Skip to content

Commit

Permalink
Remove download-boundaries-database-from-B2 code
Browse files Browse the repository at this point in the history
Downloading from artifact of GitHub Actions workflow runs is our way
forward for development test builds and future nightly CI tests.
  • Loading branch information
anthonyfok authored and wkhchow committed Apr 1, 2022
1 parent 9f36f19 commit ab644f1
Showing 1 changed file with 0 additions and 21 deletions.
21 changes: 0 additions & 21 deletions python/add_data.sh
Original file line number Diff line number Diff line change
Expand Up @@ -527,27 +527,6 @@ import_census_boundaries() {
cat opendrr-boundaries.sql.[0-9][0-9] > opendrr-boundaries.sql
fi

elif [[ "${ADD_DATA_B2_OVER_ARTIFACT,,}" =~ ^(true|1|y|yes|on)$ ]]; then
INFO "... from B2, branch ${boundaries_branch}..."

# TODO: Simplify the code below
RUN curl -O --retry 999 --retry-max-time 0 \
"https://opendrr.eccp.ca/file/OpenDRR/opendrr-boundaries-${boundaries_branch}.sql" || \
RUN curl -O --retry 999 --retry-max-time 0 \
"https://opendrr.eccp.ca/file/OpenDRR/opendrr-boundaries-${boundaries_branch}.sql" || \
RUN curl -O --retry 999 --retry-max-time 0 \
"https://f000.backblazeb2.com/file/OpenDRR/opendrr-boundaries-${boundaries_branch}.sql"

RUN curl -O --retry 999 --retry-max-time 0 \
"https://opendrr.eccp.ca/file/OpenDRR/opendrr-boundaries-${boundaries_branch}.sql.sha256sum" || \
RUN curl -O --retry 999 --retry-max-time 0 \
"https://opendrr.eccp.ca/file/OpenDRR/opendrr-boundaries-${boundaries_branch}.sql.sha256sum" || \
RUN curl -O --retry 999 --retry-max-time 0 \
"https://f000.backblazeb2.com/file/OpenDRR/opendrr-boundaries-${boundaries_branch}.sql.sha256sum"

RUN mv -fv "opendrr-boundaries-${boundaries_branch}.sql" opendrr-boundaries.sql
RUN mv -fv "opendrr-boundaries-${boundaries_branch}.sql.sha256sum" opendrr-boundaries.sql.sha256sum

else
# For a feature/topic branch, we download the artifact from the latest
# action run that matches our criteria
Expand Down

0 comments on commit ab644f1

Please sign in to comment.