From f542f9facb04dbf276af21999ca9958ee189d11a Mon Sep 17 00:00:00 2001 From: avdata99 Date: Thu, 10 Oct 2024 00:14:38 -0300 Subject: [PATCH 01/27] In progress --- docker/ckan/files/cert/localhost.cert | 22 ++ docker/ckan/files/cert/localhost.key | 27 ++ docker/ckan/files/ckan.ini | 299 ++++++++++++++++++ docker/ckan/files/etc/ckan-worker.conf | 13 + docker/ckan/files/patches/.keep | 0 docker/ckan/files/requirements.txt | 0 docker/ckan/files/scripts/entrypoint.sh | 89 ++++++ docker/ckan/files/scripts/install-ckan.sh | 45 +++ .../scripts/prepare-local-dev-extensions.sh | 78 +++++ docker/ckan/files/vars/base.env | 3 + docker/ckan/files/vars/dev.env | 1 + 11 files changed, 577 insertions(+) create mode 100644 docker/ckan/files/cert/localhost.cert create mode 100644 docker/ckan/files/cert/localhost.key create mode 100644 docker/ckan/files/ckan.ini create mode 100644 docker/ckan/files/etc/ckan-worker.conf create mode 100644 docker/ckan/files/patches/.keep create mode 100644 docker/ckan/files/requirements.txt create mode 100755 docker/ckan/files/scripts/entrypoint.sh create mode 100755 docker/ckan/files/scripts/install-ckan.sh create mode 100755 docker/ckan/files/scripts/prepare-local-dev-extensions.sh create mode 100644 docker/ckan/files/vars/base.env create mode 100644 docker/ckan/files/vars/dev.env diff --git a/docker/ckan/files/cert/localhost.cert b/docker/ckan/files/cert/localhost.cert new file mode 100644 index 0000000..eb24fc0 --- /dev/null +++ b/docker/ckan/files/cert/localhost.cert @@ -0,0 +1,22 @@ +-----BEGIN CERTIFICATE----- +MIIDtzCCAp+gAwIBAgIUG7oo+0zZ1ynU0q1NMJdhstUy9hgwDQYJKoZIhvcNAQEL +BQAwazELMAkGA1UEBhMCQVIxEDAOBgNVBAgMB0NvcmRvYmExEzARBgNVBAcMCk1l +bmRpb2xhemExDTALBgNVBAoMBE9LRk4xJjAkBgkqhkiG9w0BCQEWF2FuZHJlcy52 +YXpxdWV6QG9rZm4ub3JnMB4XDTI0MDIyMTEzMjY0MloXD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--git a/docker/ckan/files/cert/localhost.key b/docker/ckan/files/cert/localhost.key new file mode 100644 index 0000000..92d4c3d --- /dev/null +++ b/docker/ckan/files/cert/localhost.key @@ -0,0 +1,27 @@ +-----BEGIN RSA PRIVATE KEY----- +MIIEowIBAAKCAQEAvs7I/XU0xFKyVufvh+TI6ndNHwwkMH+cJG9TKtHPIlab69aM +y7QAbDVZwjCeyUxEpR1v6AOi0ROFANckSTyZkov6VfphifX75Zu9CjFlx4Nxx0QO +43ejvPeENhk/A7V/dubDOIT3/zdZ5KprgLfE0Ue7ozKQsZlDNWEDOn5tEF7y8R/y +xIqjKSOzMD1jnE6uymLymSdcUvlt+N/NVz4/brH5C82CBzx6J4dD+BcL8T6s1Bwq +bakKpDsT9wGZBCF2m1t5oxrKtCvBORjHIKmveoRC899JlSFFtF7Qgh7eqW7UbPy7 +5ifkP4fE/vmNr970hi/FVg438BSXFDIBNu6kFwIDAQABAoIBAB7+zFuP7JBvtpSz +fI+gtJqR4q9Gc6KFOEIa63GrP3CejRmUcq6sgN0TFY+cAk9E2mnQDFuuK4a3GwX1 +7OkQtQm/P100HSAiG1dDI0RCnfv4+EScY6bDyo9pzcpT846QrzILbm8B+p80yJ+C +p4/zSj+M3Yg3MJYJBYfoSHP6EZF080RrE3US2LMNeh1fnjVnTdOURWe8IWgUde5n +E8zqxyaKJ66KvmIGEqtPlN/jvr/73Itnz65l/WAN4ENlnHxbYpXwY6sJCvh/ncmy +uihoKNNViHya0fGel1BNJxtZ2ZiW5DufUazdu5l0HWPVhTnth9nUWlG1lp88ihyZ +S6MkP4ECgYEA4WJIsGeBOgbAUW1WphjQOielanVH1qeSDkvGRp2qJHdQI2T8suuV +6rTlbQcd6gjdGC7F44oEWNuy84q1uoVAAsHG0WXDzI4qKy4qOceKGOoVB8jWmIvV +SHQlt8PoCiXam+YnZe0vWpOKJYenEeAOmNi9ZuPJYgQ74zfQvvhbM/cCgYEA2Lod +0J6UmQmdsNqqcQVbdliHvW1e5L6k7sfdBSl6OsW39tG0XRvVAG74mGKBmwNMdH04 +AAr90Qr3aBlvUQ3ps6+SaAA+j7CAHMSnwy9rQdYQloq1PJeXeR4Qzw1aQIVMci2V +SugauIi+yv3dcosFvzKco6alA5cHwN3ik137yOECgYEA3EpsMb95F3Yx02TDJGVs +YOsPSxaGuM/gegimK68+9ZWIxo+WTmrlhRp6hC5Ils9DCrfsw5HK3e8e4dvZ9Az5 +m7g608BbuDvcC4h7zS2zVNa253zuAvvp439ivlLFIeYN3gL+zykc97Lte/Ey4s3U +dqChv0c1NpBc2KFdbsrgmdECgYB7GCKtBhTyYxLMizX5YYiUTC40ufUGyP1Wne/7 +6ZYB4aDeMDdYFuHBEEZkDrb8O0BmfWScKaIF5EunNaMTD2roYtUt+s2NwTrSnCOI +6drqltHvHzNXCea/pQL5BuV29f74bsl3tSLQIuLy2oO3dhy6ft2W2aSpyFNgCOaS +uvOyIQKBgDX71ooeSNXhbSscnWwa0sUetZvkB0Zz2ebje1IXOOfU5T9EI6p7arx4 +NAInkeup/oqgkoR+L5bzqdm6sh8GQ+WQnIX3NfPYS2u4rsDV+mle624DRzf7Z0kV +GnT4XNGjFzZ1yahUzF3k6baHK9O5QJAABu9MhMb3JRDHHqMYt1le +-----END RSA PRIVATE KEY----- diff --git a/docker/ckan/files/ckan.ini b/docker/ckan/files/ckan.ini new file mode 100644 index 0000000..6a44270 --- /dev/null +++ b/docker/ckan/files/ckan.ini @@ -0,0 +1,299 @@ +# +# CKAN configuration +# +# http://docs.ckan.org/en/latest/maintaining/configuration.html +# +# The %(here)s variable will be replaced with the parent directory of this file +# +[DEFAULT] + +## Default settings ############################################################ +debug = false + +[app:main] + +## General settings ############################################################ +use = egg:ckan +SECRET_KEY = +ckan.legacy_route_mappings = {} +config.mode = strict + +## Development settings ######################################################## +ckan.devserver.host = localhost +ckan.devserver.port = 5000 +ckan.devserver.threaded = false +ckan.devserver.multiprocess = 1 +ckan.devserver.watch_patterns = +ckan.devserver.ssl_cert = +ckan.devserver.ssl_key = + +## Session settings ############################################################ +ckan.user.last_active_interval = 600 +cache_dir = /tmp/%(ckan.site_id)s +beaker.session.key = ckan +beaker.session.secret = string:%(SECRET_KEY)s +beaker.session.auto = false +beaker.session.cookie_expires = false +# beaker.session.cookie_domain = .example.com +beaker.session.save_accessed_time = true +beaker.session.secure = false +beaker.session.timeout = 1200 +beaker.session.type = cookie +beaker.session.validate_key = +beaker.session.httponly = true +beaker.session.samesite = Lax + +## Database settings ########################################################### +sqlalchemy.url = +sqlalchemy.pool_pre_ping = true +# sqlalchemy.