python - Organising Flask app. SSL on one subdomain with shared static -
i have flask app i'm building has 3 distinct parts.
www. static html, css, js etc. i'm using flask build , using frozen-flask bundle static files ready hosting. secure. little amount of site contains secure content want behind https. part live on heroku (or similar). needs have similar , sense www. share static content between them. api. lives on heroku not need secured. @ moment provides cached twitter stream company's twitter account. how should best organise these things? had api. , www. in separate projects when started build secure. thought should combine them. if have single project can utilize url_for build urls. development easier because can run in one. also, feels should easier share static content. i've tried i've run headaches , don't know if right way things. got subdomains working using blueprints static files aren't loaded because (i think) need tell design static files are, of course of study want them share. i've started downwards rabbit hole i've stopped inquire here because don't want over-complicate things.
if maintain these parts in separate projects deployment easy. handling https secure. parts simple , cleanliness of having them distinct. how them share static content? re-create static files 1 repo another? can't link non-ssl versions ssl project , seems wasteful link ssl static content in non-ssl. there anyway can utilize url_for method generate urls applications outside of current one? e.g. can www. project build url page within secure. if they're in distinct projects.
that's huge wall of text, i'll stop there.
python ssl heroku flask
No comments:
Post a Comment