Skip to content

Commit

Permalink
chore: setup default user permissions
Browse files Browse the repository at this point in the history
  • Loading branch information
brunopacheco1 committed Jul 24, 2024
1 parent eb7feb1 commit 11c1a70
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
33 changes: 33 additions & 0 deletions ckan/docker-entrypoint.d/setup_default_user_permissions.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/bash

# SPDX-FileCopyrightText: 2024 PNED G.I.E.
#
# SPDX-License-Identifier: AGPL-3.0-only

# Update the config file with each extension config-options
echo "[ckan.auth] Setting up config-options"
ckan config-tool $CKAN_INI -s app:main \
"ckan.auth.create_user_via_api = False"\
"ckan.auth.create_user_via_web = False"\
"ckan.auth.user_create_groups = False"\
"ckan.auth.user_create_organizations = False"\
"ckan.auth.user_delete_groups = False"\
"ckan.auth.user_delete_organizations = False"\
"ckan.auth.anon_create_dataset = False"\
"ckan.auth.create_unowned_dataset = False"\
"ckan.auth.create_dataset_if_not_in_organization = False"\
"ckan.auth.roles_that_cascade_to_sub_groups = admin"\
"ckan.auth.public_user_details = False"\
"ckan.auth.public_activity_stream_detail = False"\
"ckan.auth.allow_dataset_collaborators = False"\
"ckan.auth.allow_admin_collaborators = False"\
"ckan.auth.allow_collaborators_to_change_owner_org = False"\
"ckan.auth.create_default_api_keys = False"\
"ckan.auth.reveal_private_datasets = False"\
"ckan.auth.enable_cookie_auth_in_api = False"\
"ckan.auth.route_after_login = home.index"\
"ckan.user_reset_landing_page = home.index"\
"ckan.upload.user.types = image"\
"ckan.upload.user.mimetypes = image/png image/jpeg"\
"ckan.upload.group.types = image text/svg"\
"ckan.upload.group.mimetypes = image/png text/svg image/svg+xml"
5 changes: 5 additions & 0 deletions ckan/docker-entrypoint.d/setup_logger_level.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
#!/bin/sh

# SPDX-FileCopyrightText: 2024 PNED G.I.E.
#
# SPDX-License-Identifier: AGPL-3.0-only


echo "[DEFAULT] Setting up debug"
#ckan config-tool $CKAN_INI -s DEFAULT "debug = $CKAN___DEBUG"

Expand Down

0 comments on commit 11c1a70

Please sign in to comment.