Project Zoe is a church management centered on what's at the heart of all ministry - people. The platform simplifies the process of managing people and their relationships between each other and the church, keeping track of data across the organization and creates a foundation for adding new features that are specific to your church.
This repo holds the Project Zoe church relationship management system (RMS) server.
-
Clone the repository:
git clone https://github.com/kanzucodefoundation/project-zoe-server.git
-
Checkout to the Develop branch
git checkout develop
-
Temporarily change
binaryTargets = ["debian-openssl-1.1.x"]
tobinaryTargets = ["native"]
inprisma/schema.prisma
-
Install dependencies with npm version 6.14.5:
npx npm@6.14.5 install
-
Create a
.env
file based on the.env.sample
.Set these environment variables in the
env
file as followsAPP_ENVIRONMENT=local
- If you are running the app locally.DB_USERNAME=<your-local-postgres-db-username>
DB_PASSWORD=<your-local-postgres-db-password>
DB_DATABASE=projectzoe-db
-
Go ahead and manually create an new postgreSQL database called:
projectzoe-db
-
Finally, spin up the project with:
npm run start:dev
-
Revert the changes in
prisma/schema.prisma
. ChangebinaryTargets = ["native"]
tobinaryTargets = ["debian-openssl-1.1.x"]
-
Create and seed data for a new tenant by running:
npm run command create-tenant demo
This will create a tenant named demo
. You can login to that tenant using the credentials found in src/seed/data/users.ts
Please Note:
- If you don't have
node.js
installed, check out this guide https://nodejs.org/en/ - This repo works with the client at https://github.com/kanzucodefoundation/project-zoe-client so be sure to set that up too.
sh: eslint: command not found
Solution: Run npm install -g eslint
then eslint --init
If that fails, other alternatives here eslint/eslint#10192
This repo is automatically deployed to the prod server using github actions. We create an .env
file during the deployment process. Rather than add each environment variable to the file one by one, we copied a complete .env
file and encrypted it using base64. We use the command:
openssl base64 -A -in .env -out .env.prod.encrypted
We then get the contents of .env.prod.encrypted
and add them as a Github Action variable called PROD_ENV_FILE