Skip to content

Commit

Permalink
issue #426 update site url in nikola conf (#438)
Browse files Browse the repository at this point in the history
* Add a dev configuration file that sets the site url to the readthedocs
location. This ensures that the production url does not leak into the
dev site.
* Update readthedocs configuration to use the dev conf file.
  • Loading branch information
oraNod authored Mar 5, 2024
1 parent adfb0da commit b6d543a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ build:
commands:
- python -m pip install --upgrade --no-cache-dir pip setuptools
- python -m pip install --upgrade -r ./requirements.in -c ./requirements.txt
- nikola build
- nikola build --conf=dev.conf.py
- mkdir -p _readthedocs/html/
- cp -r output/* _readthedocs/html/
- rm _readthedocs/html/robots.txt
2 changes: 1 addition & 1 deletion conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
BLOG_TITLE = "Ansible Community" # (translatable)
# This is the main URL for your site. It will be used
# in a prominent link. Don't forget the protocol (http/https)!
SITE_URL = "https://ansible-community-website.readthedocs.io/"
SITE_URL = "https://ansible.com/"
# This is the URL where Nikola's output will be deployed.
# If not set, defaults to SITE_URL
# BASE_URL = "https://ansible.community/"
Expand Down
2 changes: 2 additions & 0 deletions dev.conf.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
from conf import *
SITE_URL = "https://ansible-community-website.readthedocs.io/"

0 comments on commit b6d543a

Please sign in to comment.