Merge branch 'master' of https://github.com/ckan/ckan-docker into ckan-master

This commit is contained in:
mnjnz 2024-04-27 18:08:34 +02:00
commit b3ace9f631
No known key found for this signature in database
GPG Key ID: 2654E8DA034EB7B5
2 changed files with 57 additions and 21 deletions

View File

@ -204,6 +204,7 @@ To start the containers:
docker compose -f docker-compose.dev.yml up
See [CKAN images](#5-ckan-images) for more details of what happens when using development mode.
See [CKAN images](#5-ckan-images) for more details of what happens when using development mode.
#### Create an extension
You can use the ckan [extension](https://docs.ckan.org/en/latest/extensions/tutorial.html#creating-a-new-extension) instructions to create a CKAN extension, only executing the command inside the CKAN container and setting the mounted `src/` folder as output:
@ -215,19 +216,24 @@ You can use the ckan [extension](https://docs.ckan.org/en/latest/extensions/tuto
The new extension files and directories are created in the `/srv/app/src_extensions/` folder in the running container. They will also exist in the local src/ directory as local `/src` directory is mounted as `/srv/app/src_extensions/` on the ckan container. You might need to change the owner of its folder to have the appropiate permissions.
#### Running HTTPS on development mode
#### Running HTTPS on development mode
Sometimes is useful to run your local development instance under HTTPS, for instance if you are using authentication extensions like [ckanext-saml2auth](https://github.com/keitaroinc/ckanext-saml2auth). To enable it, set the following in your `.env` file:
```
```
USE_HTTPS_FOR_DEV=true
```
```
and update the site URL setting:
```
```
CKAN_SITE_URL=https://localhost:5000
```
```
After recreating the `ckan-dev` container, you should be able to access CKAN at https://localhost:5000

View File

@ -4,6 +4,7 @@ volumes:
pg_data:
solr_data:
services:
nginx:
build:
@ -53,7 +54,14 @@ services:
- /usr/lib/python3.9/site-packages
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:${CKAN_PORT}"]
test:
[
"CMD",
"wget",
"-qO",
"/dev/null",
"http://localhost:${CKAN_PORT}"
]
pycsw:
build:
@ -68,7 +76,14 @@ services:
max-file: "10"
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:5000"]
test:
[
"CMD",
"wget",
"-qO",
"/dev/null",
"http://localhost:5000"
]
db:
build:
@ -94,7 +109,15 @@ services:
max-file: "10"
restart: unless-stopped
healthcheck:
test: ["CMD", "pg_isready", "-U", "${POSTGRES_USER}", "-d", "${POSTGRES_DB}"]
test:
[
"CMD",
"pg_isready",
"-U",
"${POSTGRES_USER}",
"-d",
"${POSTGRES_DB}"
]
solr:
build:
@ -113,7 +136,14 @@ services:
- solr_data:/var/solr
restart: unless-stopped
healthcheck:
test: ["CMD", "wget", "-qO", "/dev/null", "http://localhost:${SOLR_PORT}/solr/"]
test:
[
"CMD",
"wget",
"-qO",
"/dev/null",
"http://localhost:${SOLR_PORT}/solr/"
]
redis:
image: redis:${REDIS_VERSION}