Skip to content

Latest commit

 

History

History
71 lines (42 loc) · 3.18 KB

contribution.md

File metadata and controls

71 lines (42 loc) · 3.18 KB

Contribution

Ready to contribute? Great!

This is the place to get all the necessary information to help you doing that.

Getting started

See running the project in development mode.

The best way to get started is to join our Slack or browse the existing issues (issues tagged as good first issue are highly recommended) and just pick something to work on. Open a pull request when you're done and we'll review it ASAP.

Running the project in development mode

git clone https://github.com/mini-services/miniurl.git
cd miniurl
npm install
npm run dev

I need help. What do I do?

Don't get lost trying to submit a perfect PR or getting familiar with the entire codebase before starting. Pick a task and start with it. Struggling to finish the task? Just submit the PR with a WIP tag and a team member will review it and help you find your way. You may also contact us on Slack for a faster response.

Boards

The MiniUrl team maintains boards for tracking the Roadmap and releases. You can find them here.

Troubleshooting

I'm deploying a Postgres database via helm and after uninstalling and reinstalling it, I can't connect.

This is probably due to Helm not deleting the PersistentVolumeClaims of the database, so that the data won't accidentaly be deleted along with the helm chart release.

  • Uninstall the helm chart
  • Delete the pvc: kubectl delete pvc data-<RELEASE_NAME>-postgresql-0 (release_name is usually miniurl)
  • Reinstall the helm chart

When switching to Postgres storage I get "wrong password" error

  • Check if you have Postgres installed locally and remove it or kill the process.

Common issues

How do I create a new migration in the Storage Postgres driver?

  • cd to src/services/storage/drivers/postgres folder
  • run npx knex migrate:make <MIGRATION_NAME> -x ts --migrations-directory migrations

My urls keep getting erased on development mode!

You might be using the InMemory storage driver, which means that it saves everything inside a simple JS object. On every server restart, that project will be erased and the data will be lost.

If you want to persist the data, you can edit the .env.development file and change the storage driver.

How can I run a local Postgres database for development purposes?

  • Make sure you have Docker installed
  • Run docker run -d --name postgres -e POSTGRES_PASSWORD=postgres -p 5432:5432 postgres
  • On .env.development, set the STORAGE_DRIVER to Postgres and uncomment the Postgres Storage section

How can I run a local Redis database for development purposes?

  • Make sure you have Docker installed
  • Run docker run -d --name redis -e REDIS_PASSWORD=redis -p 6379:6379 bitnami/redis
  • On .env.development, set the STORAGE_DRIVER to Redis and uncomment the Redis Storage section

Project structure

Project Structure