Skip to content

Instantly share code, notes, and snippets.

@yokotak0527
Last active September 27, 2019 03:50
Show Gist options
  • Save yokotak0527/72a6cb157e7d81d015daca219b0a7768 to your computer and use it in GitHub Desktop.
Save yokotak0527/72a6cb157e7d81d015daca219b0a7768 to your computer and use it in GitHub Desktop.
DockerでWordPressをサクッと立ち上げ

立ち上げ

$ docker run -d --name temp_wp_db -p 3306:3306 -e MYSQL_ROOT_PASSWORD=root -e MYSQL_DATABASE=wp mysql:5.7 && docker run -d --name temp_wp --link temp_wp_db:db -p 80:80 -e WORDPRESS_DB_PASSWORD=root -e WORDPRESS_DB_HOST=db -e WORDPRESS_DB_NAME=wp wordpress:latest

削除

$ docker rm -f temp_wp_db temp_wp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment