{"id":24818678,"url":"https://github.com/joshmckibbin/wp-create","last_synced_at":"2026-04-29T08:02:28.003Z","repository":{"id":273613331,"uuid":"920301839","full_name":"joshmckibbin/wp-create","owner":"joshmckibbin","description":"Create and Destroy local WordPress sites in Ubuntu","archived":false,"fork":false,"pushed_at":"2025-09-22T21:23:12.000Z","size":56,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-09-22T23:29:50.389Z","etag":null,"topics":["ubuntu","wordpress","wordpress-development","wp-cli","wsl-ubuntu","wsl2"],"latest_commit_sha":null,"homepage":"https://kibb.in/wp-create","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/joshmckibbin.png","metadata":{"files":{"readme":"README.MD","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2025-01-21T22:58:00.000Z","updated_at":"2025-09-22T21:23:15.000Z","dependencies_parsed_at":"2025-05-27T13:46:22.231Z","dependency_job_id":"5817bcfe-95c0-451d-931a-d65e527b4257","html_url":"https://github.com/joshmckibbin/wp-create","commit_stats":null,"previous_names":["joshmckibbin/wp-build","joshmckibbin/wp-create"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/joshmckibbin/wp-create","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshmckibbin%2Fwp-create","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshmckibbin%2Fwp-create/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshmckibbin%2Fwp-create/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshmckibbin%2Fwp-create/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/joshmckibbin","download_url":"https://codeload.github.com/joshmckibbin/wp-create/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/joshmckibbin%2Fwp-create/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32416146,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-29T06:29:02.080Z","status":"ssl_error","status_checked_at":"2026-04-29T06:29:00.631Z","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":["ubuntu","wordpress","wordpress-development","wp-cli","wsl-ubuntu","wsl2"],"created_at":"2025-01-30T17:37:19.697Z","updated_at":"2026-04-29T08:02:27.991Z","avatar_url":"https://github.com/joshmckibbin.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# WP-Create\n\nThis repository contains shell scripts designed to automate the creation and removal of local WordPress sites running on Ubuntu.\n\n## Prerequisites\n\n**Ubuntu (or Ubuntu running on WSL2)** with:\n- Apache with mod_rewrite enabled\n- MariaDB 10.6+ with root access\n- PHP 8.2+ with the curl, imagick, json, intl, mbstring, mysql, xml and zip extensions installed.\n- wp-cli (The `wp-create.sh` script will attempt to install it if it isn't installed)\n\n### Installing the prerequisites\nWith root access, run the following:\n```sh\napt update \u0026\u0026 apt install -y apache2 \u0026\u0026 systemctl enable apache2 \u0026\u0026 \\\na2enmod rewrite \u0026\u0026 systemctl restart apache2 \u0026\u0026 \\\napt install -y mariadb-server \u0026\u0026 mariadb-secure-installation \u0026\u0026 \\\napt install -y php php-curl php-imagick php-json php-intl php-mbstring php-mysql php-xml php-zip \u0026\u0026 \\\nsystemctl restart apache2\n```\nSet a root password for MariaDB when asked if you want to change the root password. It should be the same value as `DB_ROOT_PASS` in the `.env` file.\n\nNote: If http://localhost will not resolve after installation in WSL2, you may need to disable Fast Startup in your Windows settings and reboot your computer.\n\n## Scripts\n\n### `wp-create.sh`\nThis script uses set variables in an `.env` file to automate the creation of local WordPress sites.  \nSee the [sample .env file](.env-sample)\n\nIt prompts for a `TITLE` and a `SLUG`. If no `TITLE` is provided, it defaults to 'WordPress'.\nIf no `SLUG` is provided, it defaults to generating a `SLUG` from the `TITLE` truncated to a maximum of 15 characters.  \nIt then performs the following functions:\n\n- Creates the necessary directory structure at '`DEV_DIR`/`SLUG`/wordpress'\n- Installs `wp-cli` if necessary\n- Downloads the latest version of WordPress\n- Creates the wp-config.php file\n- Creates the database user `DB_USER` if they do not already exist\n- Creates a new database with a name generated by replacing the dashes in the '`SLUG`' with underscores (`DB_NAME`)\n- Grants all permissions for `DB_NAME` to `DB_USER`\n- Installs WordPress with a database tables prefix of 'wp_`DB_NAME`_' \n- Checks `DB_DUMP_DIR` for an existing database dump file and imports it. In this order:\n\t- `SLUG`-dev.sql\n\t- `SLUG`.sql\n\t- `SLUG`-prod.sql\n- If `SMTP_USER` and `SMTP_PASS` are set, it installs and activates the [Simple SMTP Mailer](https://wordpress.org/plugins/simple-smtp-mailer) plugin.\n\n### `wp-destroy.sh`\n**This script removes everything and should be used with extreme caution.**\n\nRemoves a WordPress site created by running the `wp-create.sh` script:\n- Prompts for the site's `SLUG` and then asks for confirmation of deletion\n- Asks if you want to delete the site's database\n- Asks if you want to delete the Apache config file\n\n## Usage\n\n1. Create and/or navigate to the directory where you want to create WordPress sites (Should be the same as `DEV_DIR`)\n\n```sh\nmkdir -p /path/to/dev/directory \u0026\u0026 cd /path/to/dev/directory\n```\n\n2. Clone (or download and extract) the repository into the directory\n\n```sh\ngit clone git@github.com:joshmckibbin/wp-create.git .\n```\n\n3. Make sure you have execute permissions for the scripts\n\n```sh\nchmod +x wp-create.sh wp-destroy.sh\n```\n\n4. Copy the `.env-sample` file to `.env` and replace the environment values with your own.\n\n```sh\ncp .env-sample .env\n```\n\n5. Run one of the shell scripts\n\n```sh\n./wp-create.sh\n```\n\n6. Profit?\n\nNote: If your development directory (`DEV_DIR`) is within your home folder (which is the default), you will need to add executable permissions to your home folder:\n\n```sh\nchmod o+x $HOME\n```\n\n### Optional: Add the script as a bash alias\n\n```sh\necho \"alias wp-create='$HOME/dev/wp-create/wp-create.sh'\" \u003e\u003e ~/.bash_aliases\n```\n\nNow you can call the script from anywhere within Ubuntu:\n\n```sh\nwp-create \"My Great WordPress Site\"\n```\n\n## License\n\nThis project is licensed under the MIT License. See the [LICENSE](LICENSE) file for details.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoshmckibbin%2Fwp-create","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoshmckibbin%2Fwp-create","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoshmckibbin%2Fwp-create/lists"}