Skip to content

Commit

Permalink
Regenerated examples for 9b35d31
Browse files Browse the repository at this point in the history
  • Loading branch information
GitHub Actions committed Sep 13, 2024
1 parent 9b35d31 commit 59edc06
Show file tree
Hide file tree
Showing 12 changed files with 54 additions and 27 deletions.
4 changes: 2 additions & 2 deletions examples/default/.copier/project.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY
_commit: b5c2b02
_commit: 52e7db6
_src_path: .
admin_email: [email protected]
author_email: [email protected]
author_name: John Doe
current_version: 2024.9.1
default_from_email: [email protected]
django_twc_ui_version: 2024.8.27
django_version: '5.0'
django_version: '5.1'
docs_site_name: Default
domain_name: default.westervelt.com
fly_app_name: default-example_owner
Expand Down
2 changes: 1 addition & 1 deletion examples/default/.pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ repos:
rev: 1.21.0
hooks:
- id: django-upgrade
args: [--target-version, "5.0"]
args: [--target-version, "5.1"]

- repo: https:/astral-sh/ruff-pre-commit
rev: v0.6.4
Expand Down
17 changes: 13 additions & 4 deletions examples/default/default/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
CI = env.bool("CI", default=False)

# 1. Django Core Settings
# https://docs.djangoproject.com/en/5.0/ref/settings/
# https://docs.djangoproject.com/en/5.1/ref/settings/

ALLOWED_HOSTS = env.list(
"ALLOWED_HOSTS", default=["*"] if DEBUG else ["localhost"], subcast=str
Expand Down Expand Up @@ -102,6 +102,15 @@
"DISABLE_SERVER_SIDE_CURSORS", default=True
)

if env.bool("ENABLE_PG_CONN_POOL", default=True):
DATABASES[db_alias]["OPTIONS"] = {
"pool": {
"min_size": env.int("PG_CONN_POOL_MIN_SIZE", default=2),
"max_size": env.int("PG_CONN_POOL_MAX_SIZE", default=4),
"timeout": env.int("PG_CONN_POOL_TIMEOUT", default=10),
}
}

DATABASE_ROUTERS = [
"email_relay.db.EmailDatabaseRouter",
]
Expand Down Expand Up @@ -213,8 +222,8 @@

MEDIA_URL = "/mediafiles/"

# https://docs.djangoproject.com/en/5.0/topics/http/middleware/
# https://docs.djangoproject.com/en/5.0/ref/middleware/#middleware-ordering
# https://docs.djangoproject.com/en/5.1/topics/http/middleware/
# https://docs.djangoproject.com/en/5.1/ref/middleware/#middleware-ordering
MIDDLEWARE = [
# should be first
"django.middleware.cache.UpdateCacheMiddleware",
Expand Down Expand Up @@ -248,7 +257,7 @@

SECRET_KEY = env.str(
"SECRET_KEY",
default="1d363a5b7b1a1e13c6e99ef493be98ceac5045f59f69cb05f04ecb09963515d0",
default="42eb58172f0c643f17382566b495469df4b095f0f09d30fd2996756aff5f1529",
)

SECURE_HSTS_INCLUDE_SUBDOMAINS = PROD
Expand Down
4 changes: 2 additions & 2 deletions examples/default/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ authors = [{name = "John Doe", email = "[email protected]"}]
dependencies = [
"attrs",
"croniter",
"django<5.1",
"django<5.2",
"django-allauth[socialaccount]",
"django-charid-field",
"django-click",
Expand Down Expand Up @@ -39,7 +39,7 @@ dependencies = [
"heroicons[django]",
"httpx",
"openpyxl",
"psycopg[binary]",
"psycopg[binary, pool]",
"sentry-sdk[django]",
"whitenoise"
]
Expand Down
4 changes: 2 additions & 2 deletions examples/postgis/.copier/project.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY
_commit: a6cca1e
_commit: 035fc1b
_src_path: .
admin_email: [email protected]
author_email: [email protected]
author_name: John Doe
current_version: 2024.9.1
default_from_email: [email protected]
django_twc_ui_version: 2024.8.27
django_version: '5.0'
django_version: '5.1'
docs_site_name: Default
domain_name: default.westervelt.com
fly_app_name: default-example_owner
Expand Down
2 changes: 1 addition & 1 deletion examples/postgis/.pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ repos:
rev: 1.21.0
hooks:
- id: django-upgrade
args: [--target-version, "5.0"]
args: [--target-version, "5.1"]

- repo: https:/astral-sh/ruff-pre-commit
rev: v0.6.4
Expand Down
17 changes: 13 additions & 4 deletions examples/postgis/default/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
CI = env.bool("CI", default=False)

# 1. Django Core Settings
# https://docs.djangoproject.com/en/5.0/ref/settings/
# https://docs.djangoproject.com/en/5.1/ref/settings/

ALLOWED_HOSTS = env.list(
"ALLOWED_HOSTS", default=["*"] if DEBUG else ["localhost"], subcast=str
Expand Down Expand Up @@ -102,6 +102,15 @@
"DISABLE_SERVER_SIDE_CURSORS", default=True
)

if env.bool("ENABLE_PG_CONN_POOL", default=True):
DATABASES[db_alias]["OPTIONS"] = {
"pool": {
"min_size": env.int("PG_CONN_POOL_MIN_SIZE", default=2),
"max_size": env.int("PG_CONN_POOL_MAX_SIZE", default=4),
"timeout": env.int("PG_CONN_POOL_TIMEOUT", default=10),
}
}

DATABASE_ROUTERS = [
"email_relay.db.EmailDatabaseRouter",
]
Expand Down Expand Up @@ -213,8 +222,8 @@

MEDIA_URL = "/mediafiles/"

# https://docs.djangoproject.com/en/5.0/topics/http/middleware/
# https://docs.djangoproject.com/en/5.0/ref/middleware/#middleware-ordering
# https://docs.djangoproject.com/en/5.1/topics/http/middleware/
# https://docs.djangoproject.com/en/5.1/ref/middleware/#middleware-ordering
MIDDLEWARE = [
# should be first
"django.middleware.cache.UpdateCacheMiddleware",
Expand Down Expand Up @@ -248,7 +257,7 @@

SECRET_KEY = env.str(
"SECRET_KEY",
default="ce2058959740529123cdd14374bb5fefd408a14440ae1449465725bc084edf8a",
default="dd671264a29a6ea5842149293892c274fb25e35085d02e0a07d15ba49282e87f",
)

SECURE_HSTS_INCLUDE_SUBDOMAINS = PROD
Expand Down
4 changes: 2 additions & 2 deletions examples/postgis/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ authors = [{name = "John Doe", email = "[email protected]"}]
dependencies = [
"attrs",
"croniter",
"django<5.1",
"django<5.2",
"django-allauth[socialaccount]",
"django-charid-field",
"django-click",
Expand Down Expand Up @@ -39,7 +39,7 @@ dependencies = [
"heroicons[django]",
"httpx",
"openpyxl",
"psycopg[binary]",
"psycopg[binary, pool]",
"sentry-sdk[django]",
"whitenoise"
]
Expand Down
4 changes: 2 additions & 2 deletions examples/with_vite/.copier/project.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Changes here will be overwritten by Copier; NEVER EDIT MANUALLY
_commit: 1a2cdb4
_commit: 1c3c79c
_src_path: .
admin_email: [email protected]
author_email: [email protected]
author_name: John Doe
current_version: 2024.9.1
default_from_email: [email protected]
django_twc_ui_version: 2024.8.27
django_version: '5.0'
django_version: '5.1'
docs_site_name: With_Vite
domain_name: with_vite.westervelt.com
fly_app_name: with_vite-example_owner
Expand Down
2 changes: 1 addition & 1 deletion examples/with_vite/.pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ repos:
rev: 1.21.0
hooks:
- id: django-upgrade
args: [--target-version, "5.0"]
args: [--target-version, "5.1"]

- repo: https:/astral-sh/ruff-pre-commit
rev: v0.6.4
Expand Down
4 changes: 2 additions & 2 deletions examples/with_vite/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ authors = [{name = "John Doe", email = "[email protected]"}]
dependencies = [
"attrs",
"croniter",
"django<5.1",
"django<5.2",
"django-allauth[socialaccount]",
"django-charid-field",
"django-click",
Expand Down Expand Up @@ -40,7 +40,7 @@ dependencies = [
"heroicons[django]",
"httpx",
"openpyxl",
"psycopg[binary]",
"psycopg[binary, pool]",
"sentry-sdk[django]",
"whitenoise"
]
Expand Down
17 changes: 13 additions & 4 deletions examples/with_vite/with_vite/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
CI = env.bool("CI", default=False)

# 1. Django Core Settings
# https://docs.djangoproject.com/en/5.0/ref/settings/
# https://docs.djangoproject.com/en/5.1/ref/settings/

ALLOWED_HOSTS = env.list(
"ALLOWED_HOSTS", default=["*"] if DEBUG else ["localhost"], subcast=str
Expand Down Expand Up @@ -102,6 +102,15 @@
"DISABLE_SERVER_SIDE_CURSORS", default=True
)

if env.bool("ENABLE_PG_CONN_POOL", default=True):
DATABASES[db_alias]["OPTIONS"] = {
"pool": {
"min_size": env.int("PG_CONN_POOL_MIN_SIZE", default=2),
"max_size": env.int("PG_CONN_POOL_MAX_SIZE", default=4),
"timeout": env.int("PG_CONN_POOL_TIMEOUT", default=10),
}
}

DATABASE_ROUTERS = [
"email_relay.db.EmailDatabaseRouter",
]
Expand Down Expand Up @@ -214,8 +223,8 @@

MEDIA_URL = "/mediafiles/"

# https://docs.djangoproject.com/en/5.0/topics/http/middleware/
# https://docs.djangoproject.com/en/5.0/ref/middleware/#middleware-ordering
# https://docs.djangoproject.com/en/5.1/topics/http/middleware/
# https://docs.djangoproject.com/en/5.1/ref/middleware/#middleware-ordering
MIDDLEWARE = [
# should be first
"django.middleware.cache.UpdateCacheMiddleware",
Expand Down Expand Up @@ -249,7 +258,7 @@

SECRET_KEY = env.str(
"SECRET_KEY",
default="a3d16090dfcb9188bf2cd7f35455e71e50dde8605db3f5582c9f630e1bd9e1e8",
default="af6bedb092aa8b092f9125562563a8dd1e3f9f4c1c9be7cc90430d447370a669",
)

SECURE_HSTS_INCLUDE_SUBDOMAINS = PROD
Expand Down

0 comments on commit 59edc06

Please sign in to comment.