Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create migration for database #126

Merged
merged 12 commits into from
Nov 27, 2023

Conversation

Maksymilian-Plywaczyk
Copy link
Contributor

@Maksymilian-Plywaczyk Maksymilian-Plywaczyk commented Nov 18, 2023

This PR is for add migration to our backend service and solve problems with geolachemy2 library with alembic migration:

  • Using alembic, create migration for our database
  • Connect auto check migration to Dockerfile for backend service
  • Create configuration for geolachemy in alembic
  • Add extension "postgis" while creating postgres container
  • Restructure Docker "api" container to have the same as local development
  • Add to pre-commit hooks "Ruff" linter
  • Configurate pyproject.toml file for "Ruff" and "Black" linters

@Maksymilian-Plywaczyk
Copy link
Contributor Author

Dodałem od siebie kilka dodatkowych rzeczy:

  • Dodanie Ruff lintera do naszego pre-commita
  • Dodanie migracji wraz z uwzględnieniem "postgisa"
  • Zmienienie struktury "api" kontenera

Sprawdźcie proszę, czy nie instaluje wam mój nadpisany plik 10_postgis.sh tych dodatkowych dodatków do postgisa.
Możecie prostą komendą to sprawdzić w konsoli PostgreSQL: SELECT * FROM pg_extension;

I tam na końcu nie powinno wam instalować: postgis_topology, postgis_tiger_geocoder

@Maksymilian-Plywaczyk Maksymilian-Plywaczyk marked this pull request as ready for review November 24, 2023 21:46
@Maksymilian-Plywaczyk
Copy link
Contributor Author

Tutaj jeszcze dyskusja gdzie wyszło, że to rozwiązanie z podmianą pliku jest jedną z opcji. Ogólnie ludzie prosili o to samo co ja, czyli możliwość konfiguracji tego postgisa
postgis/docker-postgis#187

.pre-commit-config.yaml Outdated Show resolved Hide resolved
@kyrstke
Copy link
Member

kyrstke commented Nov 27, 2023

Przejrzałem z większego, nie odpalałem u siebie

@Maksymilian-Plywaczyk Maksymilian-Plywaczyk merged commit b08dafb into backend Nov 27, 2023
1 check passed
@Maksymilian-Plywaczyk Maksymilian-Plywaczyk deleted the feature/configurate_migration branch November 27, 2023 16:32
@Fuligor Fuligor restored the feature/configurate_migration branch November 28, 2023 23:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants