By kashifShrimp
The DO Apps platform is pretty new and I am not sure if this functionality already exists or not.
I am thinking to set up our dev and stage env at subdomains with Namecheap. for example www.dev.example.com, www.stage.example.com at www.example.com.
Dev and stage will have their own separate app configured with respective GitHub branches but I will be pointing them to these subdomains via Namecheap.
Another nice to have functionality will be to restrict access to the subdomains (dev, stage) via Okta or Microsoft authenticator but it is not necessary right now.
So, is there any solution or guide that already exists? Is theoretically possible? Is there any guide available for this?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hello, thanks for trying out DigitalOcean App Platform.
With respect to subdomains and different apps, this should be possible and pretty straight forward.
Here is relevant Namecheap documentation.
For example with the “dev” app you would do something like this:
my-dev-app-zzyxx.ondigitalocean.app and you should be able to access the app at that url.dev.example.com. Since you are managing your own DNS via Namecheap, select that option. The interface should give you instructions to create a CNAME record. In Namecheap create a CNAME record that points the host dev to my-dev-app-zzyxx.ondigitalocean.app.www.dev host, add it in App Platform domains, and add CNAME record in Namecheap with host www.dev pointing to my-dev-app-zzyxx.ondigitalocean.app. Alternatively, for this 2nd step, instead of adding the domain in App Platform and adding another CNAME record; you may be able to just create a permanent URL Redirect Record within Namecheap, so that host www.dev redirects to https://dev.example.com (the subdomain you want just without the “www”). See documentation on adding subdomains. Note that this approach will result in HTTP (for www subdomain) to HTTPS redirect.For staging app, follow the same steps.
With respect to secure access for subdomains, it is something we are exploring, but I do not have any public timeline for this feature, or details how it may work. For now this would have to be implemented within your application. In simplest form, this can be done by utilizing Basic access authentication protocol. Okta or Microsoft, or LDAP access management would be more complex, and would have to be done all within the application as well.
Hope this is helpful.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.