Skip to content
Open
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
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Dockerfile for Expungement Generator's frontend.

FROM php:7.2-apache-stretch
FROM php:8.1-apache-bullseye

RUN apt-get update && \
apt-get upgrade -y && \
apt-get install -y git nano wget python2.7 libfontconfig poppler-utils cron zlib1g-dev nano unattended-upgrades apt-listchanges && \
apt-get install -y git nano wget python2.7 libfontconfig poppler-utils cron zlib1g-dev nano unattended-upgrades apt-listchanges libzip-dev && \
ln -s /usr/bin/pdftotext /usr/local/bin/pdftotext

RUN cd /usr/local/include && \
Expand Down
3 changes: 1 addition & 2 deletions Expungement-Generator/helpers/docketsearch_api.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,7 @@
// the search.
function docketNameSearch($firstName, $lastName, $dob) {
global $docketScraperAPIURL;
$ch = curl_init($docketScraperAPIURL . "/" .
"ujs/search/name/");
$ch = curl_init($docketScraperAPIURL . "/ujs/search/name/");
$jsonData = array(
"first_name" => $firstName,
"last_name" => $lastName
Expand Down
2 changes: 1 addition & 1 deletion Expungement-Generator/manage.php
Original file line number Diff line number Diff line change
Expand Up @@ -279,4 +279,4 @@ function displayAllOrgs()
$result->close();
print "</table>";
}
?>
?>
Binary file modified Expungement-Generator/templates/791SealingTemplate.docx
Binary file not shown.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ endif

.PHONY: docker
docker:
docker build -f Dockerfile --tag ${REPOSITORY}/${IMAGENAME}:${TAG} https://github.com/NateV/Expungement-Generator.git\#main
docker build -f db_dockerfile --tag ${REPOSITORY}/${IMAGENAME}_db:${TAG} https://github.com/NateV/Expungement-Generator.git\#main
docker build -f Dockerfile --platform=linux/amd64 --tag ${REPOSITORY}/${IMAGENAME}:${TAG} .
docker build -f db_dockerfile --platform=linux/amd64 --tag ${REPOSITORY}/${IMAGENAME}_db:${TAG} .

.PHONY: push
push:
Expand Down
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,20 @@ However, if your instance of the EG has users from multiple organizations, only

If a guest organization needs to record their expungements, they should host their own instance of the EG.

### Deploying

You will need to have a `.env` file with the variables:

```
REPOSITORY=
IMAGENAME=
TAG=
SECRET_KEY=

```

Once you have those with their respective values. You will need to run `make docker` and `make push` to build and push to the container registry.

## Motivation

Expungements are the most effective way to help an individual with a criminal record to find employment. It is near impossible to find decent work if you have a record that is visible to the world. Expungements are both time consuming and require the attention of a lawyer to properly prepare. But they are also very boring for lawyers to prepare. In an organization like CLS where we prepare thousands of expungement petitions a year, it is critical to speed up the process and remove much of the rote work from the lawyers working on expungements. The EG does both of those things. I am currently working on EG 2.0, which will be more accessible to non-lawyer petitioners.
Expand Down
2 changes: 1 addition & 1 deletion conf.d/disable_strict_mode.cnf
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[mysqld]
sql_mode=IGNORE_SPACE,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION
sql_mode=IGNORE_SPACE,NO_ZERO_IN_DATE,NO_ZERO_DATE,ERROR_FOR_DIVISION_BY_ZERO,NO_ENGINE_SUBSTITUTION
5 changes: 3 additions & 2 deletions db_dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
FROM mysql:5.7
FROM mysql:9.5.0

RUN apt-get update && apt-get install -y unattended-upgrades apt-listchanges
RUN microdnf update
RUN microdnf upgrade -y

COPY conf.d/disable_strict_mode.cnf /etc/mysql/conf.d/disable_strict_mode.cnf

Expand Down
5 changes: 4 additions & 1 deletion eg-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,15 @@ services:
DB_USER: eg_user
DB_PASS: somerandompassword
SENDGRID_KEY: somerandomkey
docketscaperAPIURL: "docketscraper_api"
docketscaperAPIURL: "https://recoscope-d4157e2ccc9b.herokuapp.com/api/ujs"
networks:
- eg-net
ports:
- "9090:9090"
volumes:
- type: mount
target: /data
platform: linux/amd64
db:
image: eg_db # or natev/eg-docker-db:latest
build:
Expand All @@ -43,12 +44,14 @@ services:
- eg-net
expose:
- "3306"
platform: linux/amd64
docketscraper_api:
image: "natev/docketscraper_api"
restart: always
networks:
- eg-net
expose:
- "8800"
platform: linux/amd64
networks:
eg-net:
2 changes: 1 addition & 1 deletion local-dev-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ services:
expose:
- "3306"
docketscraperapi:
image: "${REPOSITORY}/eg-docketscraper:v2.0.0"
image: "${REPOSITORY}/eg-docketscraper:v2.0.1"
restart: always
environment:
GUNICORN_LOGGER: "true"
Expand Down