Periodum project's backend.
After you have required tech stack above, feel free to run it like this.
npm install && \
npx prisma generate && \
npm run dev
# Run the db in background
docker-compose --env-file ./dev.env up -d db
# Run the app in foreground
docker-compose --env-file ./dev.env up app --build
# Run the app in background
docker-compose --env-file ./dev.env up -d app --build
--build
arg is required when you need to install new package unless you install inside the container.
You can connect to the running container via VSCode without installing NodeJS or any other dependencies on your machine. Just attach to the Periodum API container after running the container.
Please always follow the latest Prisma documentation for migrations.
# It will reset the db,
# apply all migrations
# and run the seed
# Currently it will import only Elements and Isotopes
npx migrate reset
# For help you man checkout the manual
npx prisma migrate --help
# Create a migration from changes in Prisma schema,
# apply it to the database,
# trigger generators (e.g. Prisma Client)
prisma migrate dev
# Reset your database and apply all migrations
prisma migrate reset
# Apply pending migrations to the database in production/staging
prisma migrate deploy
# Check the status of migrations in the production/staging database
prisma migrate status
Please follow the same guidelines with the main project.
feature
or bugfix
branch from the develop
branch (ex: feature/awesome-feature
) on your fork.develop
so other contributors will know that you're working on the issue. Other contributors might give you early feedback on your implementation for saving timeFeel free to join our Discord chat. After join Evrim Ağaçı's server, find us on Periodum channels.