|
| 1 | +--- |
| 2 | +title: "pvarki/docker-rasenmaeher-integration – README" |
| 3 | +--- |
| 4 | + |
| 5 | +> **Integration tag:** `1.1.0` |
| 6 | +> **Repo:** https://github.com/pvarki/docker-rasenmaeher-integration |
| 7 | +
|
| 8 | + |
| 9 | + |
| 10 | +# RASENMAEHER integrations |
| 11 | + |
| 12 | +"One Ring to rule them all, One Ring to find them, One Ring to bring |
| 13 | +them all and in the darkness bind them." |
| 14 | + |
| 15 | +Docker compositions, helpers etc to bring it all together into something |
| 16 | +resembling grand old ones. |
| 17 | + |
| 18 | +## Git submodules |
| 19 | + |
| 20 | +When cloning for the first time use: |
| 21 | + |
| 22 | + git clone --recurse-submodules -j8 git@github.com:pvarki/docker-rasenmaeher-integration.git |
| 23 | + |
| 24 | +When updating or checking out branches use: |
| 25 | + |
| 26 | + git submodule update |
| 27 | + |
| 28 | +And if you forgot to --recurse-submodules run git submodule init to fix |
| 29 | +things. |
| 30 | + |
| 31 | +The submodules are repos in their own right, if you plan to make changes |
| 32 | +into them change to the directory and create new branch, commit and push |
| 33 | +changes as usual under that directory. |
| 34 | + |
| 35 | +### Directories that are submodules |
| 36 | + |
| 37 | +> - api [https://github.com/pvarki/python-rasenmaeher-api](https://github.com/pvarki/python-rasenmaeher-api) |
| 38 | +> - cfssl [https://github.com/pvarki/docker-rasenmaeher-cfssl](https://github.com/pvarki/docker-rasenmaeher-cfssl) |
| 39 | +> - fpintegration [https://github.com/pvarki/python-rasenmaeher-rmfpapi](https://github.com/pvarki/python-rasenmaeher-rmfpapi) |
| 40 | +> - keycloak [https://github.com/pvarki/docker-keycloak](https://github.com/pvarki/docker-keycloak) |
| 41 | +> - kw_product_init |
| 42 | +> [https://github.com/pvarki/golang-kraftwerk-init-helper-cli](https://github.com/pvarki/golang-kraftwerk-init-helper-cli) |
| 43 | +> - openldap [https://github.com/pvarki/docker-openldap](https://github.com/pvarki/docker-openldap) |
| 44 | +> - miniwerk [https://github.com/pvarki/python-rasenmaeher-miniwerk](https://github.com/pvarki/python-rasenmaeher-miniwerk) |
| 45 | +> - ui [https://github.com/pvarki/rasenmaeher-ui](https://github.com/pvarki/rasenmaeher-ui) |
| 46 | +> - takserver [https://github.com/pvarki/docker-atak-server](https://github.com/pvarki/docker-atak-server) |
| 47 | +> - takintegration [https://github.com/pvarki/python-tak-rmapi](https://github.com/pvarki/python-tak-rmapi) |
| 48 | +
|
| 49 | +#### Running in local development mode |
| 50 | + |
| 51 | +TLDR: |
| 52 | + |
| 53 | + alias rmdev="docker compose -p rmdev -f docker-compose-local.yml -f docker-compose-dev.yml" |
| 54 | + rmdev build |
| 55 | + rmdev up |
| 56 | + |
| 57 | +or: |
| 58 | + |
| 59 | + alias rmlocal="docker compose -p rmlocal -f docker-compose-local.yml" |
| 60 | + rmlocal build |
| 61 | + rmlocal up |
| 62 | + |
| 63 | +OpenLDAP and keycloak-init sometimes fail on first start, just run up |
| 64 | +again. |
| 65 | + |
| 66 | +IMPORTANT: Only keep either rmlocal or rmdev created at one time or you |
| 67 | +may have weird network issues run "down" for one env before starting the |
| 68 | +other. |
| 69 | + |
| 70 | +Remember to run "down -v" if you want to reset the persistent volumes, |
| 71 | +or if you have weird issues when switching between environments. |
| 72 | + |
| 73 | +The dev version launches all the services and runs rasenmaeher-api in |
| 74 | +uvicorn reload mode so any edits you make under /api will soon be |
| 75 | +reflected in the running instance. |
| 76 | + |
| 77 | +If rasenmaeher-ui devel server complains make sure to delete |
| 78 | +ui/node_modules -directory from host first the dockder node distribution |
| 79 | +probably is not compatible with whatever you have installed on the host. |
| 80 | + |
| 81 | +## pre-commit notes |
| 82 | + |
| 83 | +Use "pre-commit run --all-files" liberally (and make sure you have run |
| 84 | +"pre-commit install"). If you get complaints about missing environment |
| 85 | +variables run "source example_env.sh" |
| 86 | + |
| 87 | +## Integration tests |
| 88 | + |
| 89 | +Pytest is used to handle the integration tests, the requirements are in |
| 90 | +tests/requirements.txt. NOTE: The tests have side-effects and expect a |
| 91 | +clean database to start with so always make sure to run "down -v" for |
| 92 | +the composition first, then bring it back up before running integration |
| 93 | +tests. |
| 94 | + |
0 commit comments