Web config HTTPs redirect on specific environments

ben's Avatar

ben

27 Oct, 2017 01:19 AM

We currently have 2 environments setup for web deploy. A staging environment which does not currently have an SSL certificate installed (this may change in the future) and a production environment which does.

Ideally I would like to setup a URL rewrite rule to redirect all HTTP traffic to the HTTPs address and in the past I've always done this using a web.config transform. However, I can't figure out how/if I can do that for a specific environment in AppVeyor (like you can in something Octopus deploy).

Is there anyway to do this or an alternative approach you recommend?

  1. Support Staff 1 Posted by Ilya Finkelshte... on 27 Oct, 2017 08:08 AM

    Ilya Finkelshteyn's Avatar

    Try web deploy parametrization. I did not test it with URL rewrite specifically but I believe it can work here.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac