I ❤ Automation
Takayuki Miyauchi
Travis CI
spacewapuu.com
. 62C6 C D G D H 3 6
It is hosted on
AWS S3 + Cloudfront.
)6D 12A C D 6 4 2 D 3 6A C D H
? H 2 6C 12A C
! 62D6 2 C ? 6 12A C CD
A52D6 D 5 A2 DH 3 2 6C
(6A H D !
. 6 424 6C ? 1 5 ?D	 (-
5 D C6 2 D 2D 42 H ? D 2 C G D CD ?6 4 4
#!/usr/bin/env bash
set -e
if [[ "false" != "$TRAVIS_PULL_REQUEST" ]]; then
echo "Not deploying pull requests."
exit
fi
if [[ "master" != "$TRAVIS_BRANCH" ]]; then
echo "Not on the 'master' branch."
exit
fi
bundle install --path vendor/bundle
bundle exec s3_website push --site . > /dev/null 2>&1
WP-CLI
2 6 H 6 6 C65 GA 4
6 H C ? 2 A
https://github.com/miya0001/wp-instant-setup
bin/wp core download --path=$WP_PATH --locale=en_US
bin/wp core config --dbhost=localhost --...
bin/wp core install ...
bin/wp rewrite structure "/archives/%post_id%"
bin/wp option update blogname "$WP_TITLE"
bin/wp option update blogdescription "$WP_DESC"
open http://127.0.0.1:$PORT
bin/wp server --host=0.0.0.0 --port=$PORT --docroot=
$WP_PATH
Infrastructure
describe command("wp --no-color plugin status jetpack" do
let(:disable_sudo) { true }
its(:exit_status) { should eq 0 }
its(:stdout){ should match /Status: Active/ }
end
Jetpack should be installed
describe command("wp option get permalink_structure") do
let(:disable_sudo) { true }
its(:exit_status) { should eq 0 }
its(:stdout){ should eq "/archives/%post_id%n" }
end
permalink_structure
should be /archives/%post_id%
Thanks!!

I love Automation

  • 1.
  • 2.
  • 3.
  • 4.
    It is hostedon AWS S3 + Cloudfront.
  • 5.
    )6D 12A CD 6 4 2 D 3 6A C D H ? H 2 6C 12A C ! 62D6 2 C ? 6 12A C CD A52D6 D 5 A2 DH 3 2 6C (6A H D ! . 6 424 6C ? 1 5 ?D (-
  • 6.
    5 D C62 D 2D 42 H ? D 2 C G D CD ?6 4 4
  • 7.
    #!/usr/bin/env bash set -e if[[ "false" != "$TRAVIS_PULL_REQUEST" ]]; then echo "Not deploying pull requests." exit fi if [[ "master" != "$TRAVIS_BRANCH" ]]; then echo "Not on the 'master' branch." exit fi bundle install --path vendor/bundle bundle exec s3_website push --site . > /dev/null 2>&1
  • 8.
  • 9.
    2 6 H6 6 C65 GA 4
  • 10.
    6 H C? 2 A
  • 11.
  • 12.
    bin/wp core download--path=$WP_PATH --locale=en_US bin/wp core config --dbhost=localhost --... bin/wp core install ... bin/wp rewrite structure "/archives/%post_id%" bin/wp option update blogname "$WP_TITLE" bin/wp option update blogdescription "$WP_DESC" open http://127.0.0.1:$PORT bin/wp server --host=0.0.0.0 --port=$PORT --docroot= $WP_PATH
  • 13.
  • 15.
    describe command("wp --no-colorplugin status jetpack" do let(:disable_sudo) { true } its(:exit_status) { should eq 0 } its(:stdout){ should match /Status: Active/ } end Jetpack should be installed
  • 16.
    describe command("wp optionget permalink_structure") do let(:disable_sudo) { true } its(:exit_status) { should eq 0 } its(:stdout){ should eq "/archives/%post_id%n" } end permalink_structure should be /archives/%post_id%
  • 17.