Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ENV BLUE_ENGINE_CNAME=$BLUE_ENGINE_CNAME

RUN apt-get update -y && \
apt-get upgrade -y && \
apt-get install nginx gcc git build-essential vim dnsutils -y && \
apt-get install nginx gcc git build-essential vim dnsutils secure-delete -y && \
apt-get clean -y && \
apt-get autoremove -y

Expand Down
16 changes: 16 additions & 0 deletions build-test-compose-locally.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# A copy of build-test-compose.yml except it has "network_mode: host"
# so you can connect it to the host's database when testing locally.
version: '3.8'
services:
ais:
network_mode: "host"
container_name: ais
image: ais
build:
context: .
dockerfile: Dockerfile
environment:
- ENGINE_DB_HOST
- ENGINE_DB_PASS
ports:
- "8080:8080"
7 changes: 6 additions & 1 deletion docker-build-files/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,18 @@ declare -a pdata_files=('alias' 'alias_streets' 'apt' 'apt_std' 'apte'
'centerline' 'centerline_streets' 'directional' 'landmarks' 'name_switch'
'saint' 'std' 'suffix' )

# Update passyunk pdata files everytime the container starts.
echo 'Pulling in passyunk package to update pdata files with command "pip install --force-reinstall git+ssh://git@private-git/CityOfPhiladelphia/passyunk.git@master"..'
pip install --force-reinstall git+ssh://git@private-git/CityOfPhiladelphia/passyunk.git@master &>/dev/null || fail "Failed to update passyunk pdata files!!"
# Delete private ssh key once pulled and running.
srm /root/.ssh/passyunk-private.key

echo "Asserting private data is in passyunk site-package folder"
for i in "${pdata_files[@]}"
do
test -f /usr/local/lib/python3.10/site-packages/passyunk/pdata/$i.csv || fail "$i.csv does not exist in venv!"
done


declare -a pdata_files=('election_block' 'usps_alias' 'usps_cityzip' 'usps_zip4s')

echo "Asserting private data is in passyunk_automation site-package folder"
Expand Down