Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revise Going Live section to be up to date and clearer #472

Merged
merged 12 commits into from
Feb 6, 2017

Conversation

Crell
Copy link
Contributor

@Crell Crell commented Jan 21, 2017

The Going Live page is long, hard to follow, and contains way too much information about SSL for most mortals. Let's fix all of those.

(This is still a WIP; I just wanted a place to store it.)

@Crell Crell added the WIP label Jan 21, 2017
to: "https://{default}/"
```

Alternatively, if you define only routes that use HTTPS Platform.sh will automatically create redirects from the HTTP to HTTPS version of each route.
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Someone please verify this is the case. @damz @ralt ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I confirm this ... I tested that before I wrote that

to your application properly. However, request to
`*---add-theme-vmwklxcpbi6zq.eu.platform.sh` will not be routed since it is not
a legitimate domain name.
Let's say we have a project on the EU cluster whose ID is "vmwklxcpbi6zq" and we created a branch called "add-theme". The generated apex domain of this environment will be `add-theme-vmwklxcpbi6zq.eu.platform.sh`. If we have a `http://*.{default}/` route defined, the generated route will be `http://*---add-theme-vmwklxcpbi6zq.eu.platform.sh/`. This means you could put any subdomain before the triple dashes to reach your application. HTTP request to both `http://foo---add-theme-vmwklxcpbi6zq.eu.platform.sh/` and `http://bar---add-theme-vmwklxcpbi6zq.eu.platform.sh/` URLs will be routed to your application properly. However, request to `http://*---add-theme-vmwklxcpbi6zq.eu.platform.sh/` will not be routed since it is not a legitimate domain name.
Copy link
Contributor Author

@Crell Crell Jan 23, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am torn on whether this belongs in the routing section or the going live section. There's a lot of overlap there, still, which makes me quite uncomfortable. Input welcome.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's wrong, anyway. The generated route will now include a random string after add-theme...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the paragraph for that change. That still doesn't answer where it goes. 😄

@@ -0,0 +1,75 @@
# Serving multiple applications
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This page is still incomplete, pending it being way easier to add multiple domains in the first place. Feedback still welcome but it's likely buggy.

@@ -0,0 +1,180 @@
# SSL in Production
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am not sure if this page is needed at all, frankly. Shouldn't most 3rd party SSL providers have their own instructions and generate keys for you? Do we really need this?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are so many problems with this page. I agree it should be deleted.

Possibly there are tiny bits that could be re-used, like "Use the Platform.sh CLI to add the certificate".

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've removed that page and moved selected sections to the main document. For now I stuck the SSL page into the old directory just in case we ever want that content back.


Configure your DNS provider to point your domain to your
[Platform.sh](https://platform.sh) Master environment.
## Old Stuff, is it relevant?
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Anything past here in this page I am not sure if we should keep or reword. My registrar lets me CNAME to foo.com just fine. Also, my read of this section is "you can't actually serve foo.com from us even though all of our documentation says you can, because reasons." Which... seems both incorrect and not a good thing to say. 😄 If kept it would still need to be greatly rewritten.

If you want your site to only be available at `http://mydomain.com` and
have `http://www.mydomain.com` redirect to `http://mydomain.com`, you
need define your `routes.yaml` as follow:
The way to do so will vary somewhat depending on your registrar, but nearly all registrars should allow you to set a CNAME. Some will call it an Alias or similar alternate name, but either way the intent is to say "this domain should always resolve to... this other domain". Add a CNAME record from your desired domain (`example.com`) to the master environment hostname you wrote down earlier.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see what you are trying to achieve here in terms of simplicity, however I think this will confuse anyone who actually understands CNAMEs, and their inability to be used on apex records. The instruction to add a CNAME from "example.com", for example, is both misleading and almost impossible. :)

I would suggest an alternative approach where we first provide advice on the apex domain, then on subdomains. Happy to take a shot at that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Except I did it on my own web site by adding a CNAME for @.garfieldtech.com to www.garfieldtech.com, which in turn CNAMEs to Platform.sh.

Do I simply have a rare non-crappy registrar? 😄


### HTTPS
### Set your domain
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This appears to duplicate the Set your domain section, above

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a 3-rd level section; the previous is 2nd level. The intent is to mirror the section above with a concrete, non-abstract example.

@Crell
Copy link
Contributor Author

Crell commented Jan 25, 2017

I've updated the DNS section to reintegrate the discussion of Apex domains and then removed the rest of the redundant content. I also dropped the multi-domain go-live page for now; it's in another branch to come back to once that's made approachable enough to document.

I consider this now ready for real review, so removing the WIP tag.

@Crell Crell removed the WIP label Jan 25, 2017
Copy link
Contributor

@OriPekelman OriPekelman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is approved. By an approver.

@OriPekelman OriPekelman merged commit 874f272 into master Feb 6, 2017
@Crell Crell deleted the going-live branch February 6, 2017 19:02
a certificate for the root domain, e.g. `example.com`, and expect to
secure `www.example.com`. The inverse is also true. Each domain can have
one certificate and it can be attached to the main domain or subdomain.
However, using an A Record is not possible as the IP address of the server may change from time to time, especially with frequent redeployments as in Platform.sh's case.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't get this ... The IP address will be those on our gateways. They are considered stable. And, some DNS provider supports adding multiple 'A' records and load balance them. Customer may consider using this kind of 'A' records when 'CNAME' record is not applicable.

On the other hand, some DNS provider supports HTTP/HTTPS redirect on apex domain. That can be used as well when 'CNAME' is not applicable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants