Nginx for Betty provides nginx and Docker integration for your Betty sites
Project description
Nginx for Betty 👵
Generate nginx and Docker artifacts for your Betty site.
Configuration
# Add to your project's configuration file:
extensions:
nginx:
configuration:
https: False
legacy_entity_redirects: True
www_directory: /var/www
https
(optional, boolean)
Whether to support HTTPS in the public nginx configuration. Requires you to set up SSL certificates yourself.
Defaults to whether or not your project's URL uses HTTPS.
legacy_entity_redirects
(optional, boolean)
Whether to generate redirects from legacy (pre Betty 0.5) entity URLs.
www_directory
(optional, string)
The www directory to serve.
Defaults to your project's www directory.
Usage
Add the extension to your project configuration. Whenever you generate your site, nginx artifacts will be created.
Additionally, use betty nginx-generate to create these same artifacts without also generating your site.
Launch a Docker container to serve your site locally with betty nginx-serve, or betty nginx-serve --public to launch
a container to serve your site publicly, over the internet.
Docker & known limitations
The Docker images do not yet support HTTPS connections. When hosting your site over HTTPS, you must use a proxy to terminate HTTPS connections and forward HTTP traffic to the container.
Artifacts
The Nginx extension generates the following artifacts relative to your project's output directory:
./nginx/content_negotiation.luaThe Lua code the nginx configuration uses for content negotiation. It must be placed in your nginx'slua_package_path../nginx/nginx.confYour site's public nginx configuration file. You may deploy this anywhere. You MUST configurelua_package_path. If you are using HTTPS, you MUST configure SSL certificates../nginx/DockerfleA Docker image build manifest. You may use this to run your own containers. Nginx configuration MUST be placed in/etc/nginx/conf.d, and the WWW directory MUST exist at/var/www/betty.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file betty_nginx-0.2.0a10.tar.gz.
File metadata
- Download URL: betty_nginx-0.2.0a10.tar.gz
- Upload date:
- Size: 46.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e0c1721fbdfa0c317c663f1f84f724fc36ca5fee63984b0654f0caa10ecf5f58
|
|
| MD5 |
bc66943dfd44a5603745bf3729e3c052
|
|
| BLAKE2b-256 |
898a1b3c1a842096b3b471935dd934f79d0e3d7fa8db8f89954b06fbd24764db
|
File details
Details for the file betty_nginx-0.2.0a10-py3-none-any.whl.
File metadata
- Download URL: betty_nginx-0.2.0a10-py3-none-any.whl
- Upload date:
- Size: 35.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d4a7b0854241b2e56249f778ecd1c4ca2fcb314ab7c30b04ee2f7472ca3effbf
|
|
| MD5 |
bae97b4945ec8f2775f2242e3116c8c5
|
|
| BLAKE2b-256 |
e7bc03daa3439d7e7d53310f993c3cdaa4b10d5afe89ad78b50680bc824acd78
|