{"id":25927857,"url":"https://github.com/samirelanduk/server-scripts","last_synced_at":"2026-04-29T21:37:17.654Z","repository":{"id":69802579,"uuid":"193752088","full_name":"samirelanduk/server-scripts","owner":"samirelanduk","description":"A collection of bash scripts I wrote to make setting up sites on an nginx server easy","archived":false,"fork":false,"pushed_at":"2020-05-17T12:39:07.000Z","size":10,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-12-02T06:35:12.598Z","etag":null,"topics":["django","gunicorn","nginx","nginx-configuration","provisioning","provisioning-scripts"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/samirelanduk.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2019-06-25T17:17:47.000Z","updated_at":"2022-01-06T03:15:23.000Z","dependencies_parsed_at":"2023-07-16T15:22:33.394Z","dependency_job_id":null,"html_url":"https://github.com/samirelanduk/server-scripts","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/samirelanduk/server-scripts","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samirelanduk%2Fserver-scripts","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samirelanduk%2Fserver-scripts/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samirelanduk%2Fserver-scripts/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samirelanduk%2Fserver-scripts/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/samirelanduk","download_url":"https://codeload.github.com/samirelanduk/server-scripts/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/samirelanduk%2Fserver-scripts/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32445543,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T20:22:27.477Z","status":"ssl_error","status_checked_at":"2026-04-29T20:22:26.507Z","response_time":110,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["django","gunicorn","nginx","nginx-configuration","provisioning","provisioning-scripts"],"created_at":"2025-03-03T21:10:54.589Z","updated_at":"2026-04-29T21:37:17.649Z","avatar_url":"https://github.com/samirelanduk.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Server Scripts\n\nThese are useful bash scripts for setting up websites using nginx. This is not the only way to setup websites. This is how I setup websites.\n\nNOTE: While anyone is welcome to use these, and while they should work fine, I take absolutely no responsibilty for anything which may go awry while using them.\n\nMost of the files here are for individual tasks, but there are four scripts which you may find useful:\n\n## `provision-static-site.sh`\n\nThis script configures a static site in nginx - it will just look for files in some directory. It creates a certificate, makes the relevant directory, and creates a placeholder index.html.\n\nIt requires nginx and letsencrypt. You give it a domain name and, optionally, a location for the website directories folder (default is $HOME).\n\n\n## `provision-spa-site.sh`\n\nExactly the same as the static site provisioning script, except nginx will serve index.html if it gets an unfamiliar URL, rather than returning 404. This is the required behaviour for single page application frameworks like react.\n\n## `provision-django-site.sh`\n\nThis script configures a django site in nginx - incoming requests are passed to gunicorn apart from /static/ and /uploads/ URLs.\n\nNo database stuff is done.\n\nIt requires nginx, letsencrypt, python, and uses systemd. You give it a domain name, a python executable name and, optionally, a location for the website directories folder (default is $HOME).\n\n## `delete-site.sh`\n\nDeletes a website on the server - SSL certificates, nginx conf files, source files - everything pertaining to this website (apart from database stuff) will be deleted.\n\nUse with caution, and again - I accept no responsibility for anything unexpected that might happen. I have used this script many times since writing it and it always goes fine, but you never know...\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsamirelanduk%2Fserver-scripts","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsamirelanduk%2Fserver-scripts","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsamirelanduk%2Fserver-scripts/lists"}