{"id":16961070,"url":"https://github.com/ricsanfre/public-host-preparation","last_synced_at":"2026-04-19T03:32:39.271Z","repository":{"id":111459594,"uuid":"523002497","full_name":"ricsanfre/public-host-preparation","owner":"ricsanfre","description":"Public host automation tasks","archived":false,"fork":false,"pushed_at":"2023-02-19T10:00:18.000Z","size":8,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-21T15:51:31.140Z","etag":null,"topics":["ansible","backup","docker","docker-compose","gdrive","internet-facing","restic"],"latest_commit_sha":null,"homepage":"","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/ricsanfre.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}},"created_at":"2022-08-09T15:17:24.000Z","updated_at":"2023-02-26T01:56:35.000Z","dependencies_parsed_at":null,"dependency_job_id":"fc6df841-d593-472e-b44e-24aa13bbb071","html_url":"https://github.com/ricsanfre/public-host-preparation","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ricsanfre/public-host-preparation","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricsanfre%2Fpublic-host-preparation","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricsanfre%2Fpublic-host-preparation/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricsanfre%2Fpublic-host-preparation/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricsanfre%2Fpublic-host-preparation/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ricsanfre","download_url":"https://codeload.github.com/ricsanfre/public-host-preparation/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ricsanfre%2Fpublic-host-preparation/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31993778,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T20:23:30.271Z","status":"online","status_checked_at":"2026-04-19T02:00:07.110Z","response_time":55,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["ansible","backup","docker","docker-compose","gdrive","internet-facing","restic"],"created_at":"2024-10-13T22:50:55.917Z","updated_at":"2026-04-19T03:32:39.247Z","avatar_url":"https://github.com/ricsanfre.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Internet-facing host setup\n\nThis repo contains a set of Ansible playbooks for preparing a host running on Public Cloud\n\n## Configuration\n\nSet inventory file `inventory.yml` containing the hosts to be configured.\n\nIp addresses and SSH remote users.\n\n\n### Dependencies installation\n\nSome ansible roles are needed.\n\n```shell\nansible-galaxy install -r requirements.yml\n```\n\n## Backup Configuration\n\nHosts are configured to use Google Drive as backup repository, using [rclone](https://rclone.org/) integration in [restic](https://restic.net/).\n\nFollow procedure indicated in [rclone documentation](https://rclone.org/drive/) to configure a Google's service account and obtain service account credentials file (JSON file). This need to be placed in `files/google_service_account.json`\n\nrclone remote repository is configured as `gdrive`\n\nBackup/restic configuration for each host can be specified in host var files (`host_vars`)\n\n\nTo configure backup on remote host execute the command:\n\n```shell\nansible-playbook configure_backup.yml\n```\n\n\n### Empty Gdrive Trash commands\n\nDeleted files are moved to gdrive trash. Maintenance tasks requires to empty trash periodically.\n\n`rclone cleanup` command will empty gdrive trash\n```shell\nrclone cleanup gdrive:\u003cpath\u003e\n```\n\nThere is an open issue where emptyin trash is not working properly (https://github.com/rclone/rclone/issues/3964) and a specific command need to be executed instead. See this [rclone forum post](https://forum.rclone.org/t/empty-google-drive-trash/14331) for more details.\n```shell\nrclone delete gdrive: --drive-trashed-only --drive-use-trash=false --verbose=2 --fast-list\n```\n\n\n## Docker Installation\n\nDocker and docker-compose can be installed for easily selfhosting applications\n\n```shell\nansible-playbook configure_docker.yml\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fricsanfre%2Fpublic-host-preparation","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fricsanfre%2Fpublic-host-preparation","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fricsanfre%2Fpublic-host-preparation/lists"}