{"id":17823062,"url":"https://github.com/artofcode-/scot","last_synced_at":"2025-03-18T14:31:14.433Z","repository":{"id":69665768,"uuid":"102795774","full_name":"ArtOfCode-/SCOT","owner":"ArtOfCode-","description":"Disaster response and relief management for volunteer teams.","archived":false,"fork":false,"pushed_at":"2017-12-10T17:06:25.000Z","size":734,"stargazers_count":5,"open_issues_count":15,"forks_count":4,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-02-28T10:09:06.852Z","etag":null,"topics":["disaster-response","rails","relief-management","volunteer-teams"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ArtOfCode-.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2017-09-07T23:36:46.000Z","updated_at":"2020-04-10T02:28:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"dd3cf95d-1672-441d-9fa5-a4f2c2f2614e","html_url":"https://github.com/ArtOfCode-/SCOT","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ArtOfCode-%2FSCOT","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ArtOfCode-%2FSCOT/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ArtOfCode-%2FSCOT/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ArtOfCode-%2FSCOT/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ArtOfCode-","download_url":"https://codeload.github.com/ArtOfCode-/SCOT/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243933431,"owners_count":20370986,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["disaster-response","rails","relief-management","volunteer-teams"],"created_at":"2024-10-27T17:50:41.217Z","updated_at":"2025-03-18T14:31:14.428Z","avatar_url":"https://github.com/ArtOfCode-.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CrowdRescue\nDisaster response and relief management for volunteer teams\n\n## Prerequisites\nYou'll need Ruby and MySQL installed to be able to set CrowdRescue up locally.\n\n## Setup\n - Clone the repository and `cd` into the repository directory.\n - Install the required gems:\n ```bash\n $ bundle install\n ```\n - Copy sample config to real config, and fill in any missing values. You'll need to [set up a Google Maps API token](https://developers.google.com/maps/documentation/javascript/get-api-key) to insert in the config file.\n ```bash\n$ cp config/settings.sample.yml config/settings.yml\n ```\n - Same for database config: copy and fill in your real username and password:\n ```bash\n$ cp config/database.sample.yml config/database.yml\n ```\n - Run MySQL if it is not already running.\n\nYou can check if MySQL is running with\n\n```bash\n$ ps aux | grep mysql\n```\n\nOn Linux, start MySQL with\n\n```bash\n$ sudo systemctl restart mysql\n```\n\nOn Mac, use\n\n```bash\n$ mysqld\n```\n\n - Set up the database:\n\n```bash\n$ rails db:create\n$ rails db:schema:load\n$ rails db:migrate\n```\n\n - Run the server with\n ```bash\n $ rails s\n ```\n\n## MySQL permissions setup\n\nYou may see an error about MySQL permissions. If you do, you need to set up your user's permissions within MySQL.\n\nYou'll want to log in to MySQL as `root` so you can make these changes. Make sure MySQL is running first. On MacOS, run:\n\n```bash\n$ sudo mysql\n```\n\nEnter your password (the one you normally use with `sudo`, not a MySQL related password). \n\nOn Linux, use:\n\n```bash\n$ mysql -u root -p\n```\n\nYou'll now be in the MySQL console.\n\nChange to the system database for MySQL.\n\n```sql\nmysql\u003e use mysql;\n```\n\nList the MySQL users.\n\n```sql\nmysql\u003e select user from user;\n+---------------+\n| user          |\n+---------------+\n| \u003cyour name\u003e   |\n| mysql.session |\n| mysql.sys     |\n| root          |\n+---------------+\n```\n\n`\u003cyour name\u003e` should be there; this should be the same name as the `username` listed in `config/database.yml`.\n\nLook at the grants given to your user.\n\n```sql\nmysql\u003e show grants for \u003cyour name\u003e@localhost;\n```\n\nIf you're having permission errors you probably do not have the needed grants.\n\nGrant yourself all privileges on all tables on `crowdrescue_dev`. This will have been created when you ran the rails setup commands listed above.\n\n```sql\nmysql\u003e GRANT ALL PRIVILEGES ON `crowdrescue_dev`.* TO '\u003cyour name\u003e'@'localhost';\n```\n\nIf you have other databases set up locally, like `crowdrescue_test` or `crowdrescue_prod`, grant yourself permission on those as well.\n\n```sql\nmysql\u003e GRANT ALL PRIVILEGES ON `crowdrescue_test`.* TO '\u003cyour name\u003e'@'localhost';\nmysql\u003e GRANT ALL PRIVILEGES ON `crowdrescue_prod`.* TO '\u003cyour name\u003e'@'localhost';\n\n```\n\nThen tell MySQL to apply these changes with\n\nNow make sure the privileges got added properly:\n\n```sql\nmysql\u003e show grants for \u003cyour name\u003e@localhost;\n+--------------------------------------------------------------------------------------+\n| Grants for \u003cyour name\u003e@localhost                                                           |\n+--------------------------------------------------------------------------------------+\n| GRANT ALL PRIVILEGES ON `crowdrescue_dev`.* TO '\u003cyour name\u003e'@'localhost' WITH GRANT OPTION |\n| GRANT ALL PRIVILEGES ON `crowdrescue_test`.* TO '\u003cyour name\u003e'@'localhost'                  |\n+--------------------------------------------------------------------------------------+\n```\n\nYou can now leave the MySQL console.\n\n```sql\nmysql\u003e exit\nBye\n```\n\nNow try running SCOT again, you should have the permissions you need.\n\n## License\n    SCOT - disaster response/relief management for volunteer teams\n    Copyright (c) 2017 Owen Jenkins and contributors\n\n    This program is free software: you can redistribute it and/or modify\n    it under the terms of the GNU Affero General Public License as published\n    by the Free Software Foundation, either version 3 of the License, or\n    (at your option) any later version.\n\n    This program is distributed in the hope that it will be useful,\n    but WITHOUT ANY WARRANTY; without even the implied warranty of\n    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the\n    GNU Affero General Public License for more details.\n\n    You should have received a copy of the GNU Affero General Public License\n    along with this program.  If not, see \u003chttp://www.gnu.org/licenses/\u003e.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fartofcode-%2Fscot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fartofcode-%2Fscot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fartofcode-%2Fscot/lists"}