sintaxi / surge

CLI for the surge.sh CDN
https://surge.sh
2.88k stars 136 forks source link

Publish subdirectory #223

Open mstijak opened 8 years ago

mstijak commented 8 years ago

Is it possible to publish a project into a subdirectory?

I tried using name.surge.sh/directory as domain name but that doesn't seem to be working.

Different parts of my site are developed in different repositories and it would be great to publish each part independently.

christoga commented 8 years ago

This may help: https://surge.sh/help/redirecting-www-to-root-automatically

balupton commented 7 years ago

For the use case I have, this is preferred. As we are using surge to publish the releases of our projects. Currently, there will be:

While this is fine, it is a bit extreme. It would be nice if we could just deploy to:

If there is no index.html at PROJECT.ORGANISATION.surge.sh it can just be a directory listing.

cbroberg commented 7 years ago

I have the same problem wanting to publish to domain.com/example1 and domain.com/example2, still haven't found anything working

andreasplesch commented 7 years ago

I am working around this by using recursive wget from the single deploy site PROJECT.surge.sh to get everything, by then adding/replacing subdirectories, and finally backdeploying everything to the site. This adds some, meaning a lot of, traffic so may be not feasible for large projects/frequent deploys but bandwidth is often cheap or included with services like travis. Just instantiating a site per commit/PR seems popular, however.