Mercurial > p > roundup > code
comparison doc/installation.txt @ 6522:e6ae8188f61a
issue2551163 Docker/containerization support
New multi-stage build including drivers for mysql and postgresql
along with brotli and zstd HTTP compression methods.
Documentation in installation.txt.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Fri, 05 Nov 2021 23:44:14 -0400 |
| parents | 8f1b91756457 |
| children | 34cbd0e633d2 |
comparison
equal
deleted
inserted
replaced
| 6521:42ff671d7f41 | 6522:e6ae8188f61a |
|---|---|
| 214 You can also use the ``--prefix`` option to use a completely different | 214 You can also use the ``--prefix`` option to use a completely different |
| 215 base directory, if you do not want to use administrator rights. If you | 215 base directory, if you do not want to use administrator rights. If you |
| 216 choose to do this, you may have to change Python's search path (sys.path) | 216 choose to do this, you may have to change Python's search path (sys.path) |
| 217 yourself. | 217 yourself. |
| 218 | 218 |
| 219 Creating a Docker Container | |
| 220 ~~~~~~~~~~~~~~~~~~~~~~~~~~~ | |
| 221 | |
| 222 If you don't want to install it natively, you can create a Docker | |
| 223 container. This uses the Dockerfile in the scripts directory. The | |
| 224 roundup code in the distribuion and any changes will be used. The | |
| 225 build command is:: | |
| 226 | |
| 227 docker build -t roundup-app --rm -f scripts/Dockerfile . | |
| 228 | |
| 229 It supports the following backends: anydbm, sqlite, mysql and | |
| 230 postgresql. Mysql and postgresql support hasn't been tested, but the | |
| 231 Python modules are built and available. See scripts/requirement.txt | |
| 232 for the additional modules that are installed. | |
| 233 | |
| 234 If you want to build a docker from the latest release on PyPI, you can | |
| 235 use:: | |
| 236 | |
| 237 docker build -t roundup-app --build-arg="source=pypi" \ | |
| 238 --rm -f scripts/Dockerfile . | |
| 239 | |
| 240 Once the docker is created, run it with:: | |
| 241 | |
| 242 docker run --rm -p 9017:8080 \ | |
| 243 -v /.../issue.tracker:/usr/src/app/tracker \ | |
| 244 roundup-app:latest | |
| 245 | |
| 246 This will make the tracker available at: | |
| 247 ``http://yourhost:9017/issues/``. | |
| 248 | |
| 249 The ``-p`` option maps an external port (9017) to proxy the roundup | |
| 250 server running at port 8080 to the outside. The ``-v`` option maps a | |
| 251 directory from the host into the docker container. It should be a | |
| 252 tracker home directory. Note that uid 1000 is used by roundup. So the | |
| 253 uid of the directory must be 1000. | |
| 254 | |
| 255 If you want to run multiple trackers, create a subdirectory for each | |
| 256 tracker home under the volume mount point. Then invoke ``docker run`` | |
| 257 passing the roundup-server tracker specifications like:: | |
| 258 | |
| 259 docker run --rm -p 9017:8080 \ | |
| 260 -v /.../issue.tracker:/usr/src/app/tracker \ | |
| 261 roundup-app:latest tracker1=tracker1_home tracker2=tracker2_home | |
| 262 | |
| 263 | |
| 264 This will set up two trackers that can be reached at | |
| 265 ``http://yourhost:9017/tracker1/`` and ``http://yourhost:9017/tracker2/``. | |
| 266 | |
| 267 If you need to install and initialize the trackers, you can get a | |
| 268 shell without starting the roundup-server using:: | |
| 269 | |
| 270 docker run -it \ | |
| 271 -v /.../issue.tracker:/usr/src/app/tracker \ | |
| 272 --entrypoint sh roundup-app:latest | |
| 273 | |
| 274 Now you can configure your tracker using ``roundup-admin -i tracker`` | |
| 275 using the directions below. | |
| 276 | |
| 277 If you need to access your container while the server is running you | |
| 278 can use:: | |
| 279 | |
| 280 docker exec -it c0d5 sh | |
| 281 | |
| 282 where ``c0d5`` is the id prefix for the running container. | |
| 219 | 283 |
| 220 Configuring your first tracker | 284 Configuring your first tracker |
| 221 ------------------------------ | 285 ------------------------------ |
| 222 | 286 |
| 223 1. To create a Roundup tracker (necessary to do before you can | 287 1. To create a Roundup tracker (necessary to do before you can |
