Skip to content

Purging through curl

Benjamin Adams edited this page Nov 21, 2016 · 1 revision

If the purge action takes longer than the timeout value (60s I think) then nginx will cut off CKAN from completing the action because it takes too long.

The work around is to log onto the machine running the CKAN container and purge using curl.

curl 'http://localhost:8080/ckan-admin/trash' -H 'Authorization: <api-token>' -H 'Referer: http://localhost:8080/ckan-admin/trash' -H 'Origin: http://localhost:8080' -H 'Upgrade-Insecure-Requests: 1' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.116 Safari/537.36' -H 'Content-Type: application/x-www-form-urlencoded' --data 'purge-packages=purge' --compressed
Clone this wiki locally