想定読者
ValetでLaravel環境を構築したい人。
HomebrewとPHPは事前にインストールが完了していること。
zshを使用してインストールします。
やること
- Composerのインストール
- PostgreSQLのインストール
- Valetインストール
- Laravel アプリケーションの起動
ローカル環境の確認
- PHPのバージョン確認
-> % php -v
PHP 7.3.6 (cli) (built: Jun 17 2019 08:40:34) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.6, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.3.6, Copyright (c) 1999-2018, by Zend Technologies
Composerのインストール
-> % php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
-> % php -r "if (hash_file('sha384', 'composer-setup.php') === 'a5c698ffe4b8e849a443b120cd5ba38043260d5c4023dbf93e1558871f1f07f58274fc6f4c93bcfd858c6bd0775cd8d1') { echo 'Installer verified'; } else { echo 'Installer corrupt'; unlink('composer-setup.php'); } echo PHP_EOL;"
Installer verified
-> % php composer-setup.php
All settings correct for using Composer
Downloading...
Composer (version 1.9.0) successfully installed to: /Users/path/composer.phar
Use it: php composer.phar
-> % php -r "unlink('composer-setup.php');"
-> % ls
Applications Downloads Music composer.phar
Desktop Library Pictures dev
Documents Movies Public
ここまでの処理が正常に完了したら、 composer.phar というファイルが生成されているはずです。 この composer.phar が composer コマンドの実体になります。
うまくいかない場合は公式ページのコマンドを参考にする。
-> % sudo mv composer.phar /usr/local/bin/composer
Password:
-> % composer --version
Composer version 1.8.6 2019-06-11 15:03:05
最新ではない??
self-update
を使えば自動で最新のリリースまで上がります。
-> % composer self-update
Updating to version 1.9.0 (stable channel).
Downloading (100%)
Use composer self-update --rollback to return to version 1.8.6
-> % composer --version
Composer version 1.9.0 2019-08-02 20:55:32
PostgreSQLインストール
-> % brew install postgresql
Updating Homebrew...
==> Auto-updated Homebrew!
Updated 2 taps (homebrew/core and homebrew/services).
==> New Formulae
asyncplusplus dhall-bash libvncserver pygments
aws-cdk dive lightgbm quickjs
aws-google-auth fastmod llvm@8 ripgrep-all
base91 faust minizip2 scc
bazelisk ghc@8.6 msgpack-tools scs
benthos git-revise now-cli shadowenv
berglas go-md2man nushell starship
bitwise go@1.12 octant tflint
borgmatic grpc-swift open-image-denoise tmuxinator
broot kepubify pastel traefik@1
clp kubebuilder pdfcpu whalebrew
codespell lazydocker pdftk-java wiiuse
coinutils lerna pokerstove wtfutil
cpl libsigc++@2 protobuf@3.7 zrepl
cpu_features libspng pulp
==> Updated Formulae
apr-util ✔ libu2f-server
aspell ✔ libusb
curl-openssl ✔ libuv
freetds ✔ libvirt
glib ✔ libvisio
jemalloc ✔ libvmaf
libevent ✔ libvoikko
libpq ✔ libvpx
libssh2 ✔ libvterm
mysql ✔ libwebsockets
nghttp2 ✔ libxkbcommon
openldap ✔ libxml++
openssl ✔ libxml++3
php ✔ libxmlsec1
python ✔ libzdb
re2c ✔ lighttpd
readline ✔ link-grammar
rtmpdump ✔ linkerd
sqlite ✔ links
webp ✔ liquibase
abcm2ps liquid-dsp
abcmidi lldpd
abyss llvm
ace llvm@7
ack lmdb
activemq lmod
activemq-cpp lnav
adwaita-icon-theme logrotate
afflib logstash
afl-fuzz logtalk
agedu lolcat
aircrack-ng lsd
algernon lsof
aliyun-cli luvit
allure lxc
alpine lynx
amap lz4
amazon-ecs-cli mackup
ammonite-repl macvim
amqp-cpp mafft
amtk mage
angband magic-wormhole
angular-cli mailutils
anjuta makensis
annie makepkg
ansible mame
ansible-lint mariadb
ansible@1.9 mariadb-connector-c
ansible@2.0 mariadb-connector-odbc
ansiweather mariadb@10.0
ant mariadb@10.1
anycable-go mariadb@10.2
apache-arrow mariadb@10.3
apache-arrow-glib maven
apache-flink mawk
apache-geode maxwell
apache-spark mbedtls
apib md5sha1sum
appscale-tools mdbook
aqbanking mdds
arangodb media-info
aravis mediaconch
armadillo megacmd
armor megatools
arpack memcached
arping memcacheq
asdf menhir
asio mercurial
ask-cli mesa
astrometry-net meson
atk mesos
atkmm metabase
atlantis metricbeat
atomist-cli mfterm
ats2-postiats mg
auditbeat mgba
autorest micronaut
avfs midnight-commander
avro-c mill
avro-cpp miller
avro-tools mingw-w64
aws-okta minio
aws-sdk-cpp minio-mc
awscli miniserve
axel mit-scheme
azure-cli mitmproxy
azure-storage-cpp mkcert
babel mkl-dnn
babeld mktorrent
babl mkvtoolnix
bacula-fd mmark
badtouch mmseqs2
balena-cli moarvm
ballerina mockserver
baobab moco
bareos-client modules
basex moe
bash molecule
bash-snippets monero
bat monetdb
bazel mongo-c-driver
bbftp-client mongoose
bcftools monit
bear monitoring-plugins
bedtools monkeysphere
bee mono
berkeley-db mosh
bettercap mosquitto
bibtexconv mp3cat
bigloo mpg123
binaryen mpop
bind mrboom
bindfs msitools
biogeme msmtp
bison mtr
bit mupdf
bitchx mutt
bitcoin mycli
bitrise mydumper
black mypy
blueutil mysql++
boost mysql-client
boost-bcp mysql-connector-c++
boost-build mysql@5.7
boost-mpi mytop
boost-python n
boost-python3 nagios
botan nagios-plugins
breezy nano
bro nativefier
btfs nats-server
btparse nats-streaming-server
btpd ncdc
buildifier ncdu
buildkit ncmpcpp
buku nco
bundletool ncrack
burp ncview
byacc neo4j
bzip2 neofetch
c-blosc neomutt
cabal-install neon
cadaver neovim
caddy net-snmp
caf netdata
caffe netlify-cli
cairomm newman
cake newsboat
calcurse newt
calicoctl nfdump
camlp4 nginx
camlp5 ngircd
cargo-completion nickle
cash-cli nim
catch2 nlohmann-json
ccache nmap
ccls nmh
ceres-solver nnn
certbot node
certstrap node-build
cfn-lint node@10
cfr-decompiler node@8
cfssl nomad
cgdb nopoll
cglm noti
cgrep nqp
chakra nrpe
chamber nsd
chapel nspr
charm-tools nsq
checkbashisms nss
checkstyle ntl
chipmunk ntp
chronograf nuget
cimg numpy
circleci nwchem
citus nylon
cjdns nyx
ckan nzbget
clamav oath-toolkit
click ocaml
clingo ocaml-findlib
clojure ocaml-num
closure-compiler ocamlbuild
cmake ocamlsdl
cmix ocproxy
cmus ocrad
cnats ocrmypdf
cockroach octave
cocoapods ode
cointop offlineimap
collectd omega
collector-sidecar omniorb
commandbox oniguruma
compcert onscripter
composer ooniprobe
conan opa
configen opam
conjure-up open-jtalk
consul open-mesh
consul-template open-mpi
contentful-cli open-zwave
convox openapi-generator
coturn openblas
cppcheck opencolorio
cpprestsdk openconnect
cql opencv
credstash opencv@2
cromwell opencv@3
crowdin openfortivpn
cryptol openhmd
crystal openimageio
crystal-icr openkim-models
csound openrct2
cubelib opensaml
cucumber-cpp opensc
curl openssh
cxxopts openssl@1.1
cypher-shell openttd
cython openvpn
dartsim operator-sdk
datamash ophcrack
dav1d opusfile
davix orc
davmail orc-tools
dbhash ori
dbmate osc
dbus oscats
dcd osquery
dcmtk osslsigncode
dcos-cli overmind
ddgr owfs
deark p11-kit
debianutils p7zip
deno packer
dependency-check packer-completion
desktop-file-utils pagmo
devspace paket
dhall pandoc-citeproc
dhall-json pango
di pangomm
dialog parallel
diamond passenger
dieharder pazpar2
diff-pdf pc6001vx
diff-so-fancy pcb2gcode
diffoscope pcsc-lite
digdag pdfcrack
direvent pdftoipe
diskus pdns
distcc pdnsrec
dita-ot pegtl
django-completion percona-server
dmd percona-toolkit
dmg2img percona-xtrabackup
dnscrypt-proxy perltidy
dnscrypt-wrapper petsc
dnsperf petsc-complex
dnsviz pev
docfx pgbouncer
docker pgcli
docker-completion pgroonga
docker-compose pgweb
docker-credential-helper phoronix-test-suite
docker-machine php-code-sniffer
docker-machine-completion php-cs-fixer
doctl php@7.1
docutils php@7.2
doitlive phpmd
dosbox-x phpstan
dovecot phpunit
doxygen picard-tools
drafter pijul
drone-cli pilosa
dscanner pinboard-notes-backup
dtc pioneer
dub pip-completion
duck pipx
duo_unix pjproject
duplicity pkcs11-helper
dyld-headers planck
dylibbundler plantuml
dynamips platformio
dynare platypus
ecasound pmd
eccodes png++
efl pngquant
eiffelstudio poco
ejabberd podofo
ekg2 pony-stable
elasticsearch ponyc
elektra poppler
elinks postgis
elixir postgresql
elm-format postgresql@10
emacs postgresql@9.4
embree postgresql@9.5
embulk postgresql@9.6
emscripten postgrest
encfs pre-commit
enchant prefixsuffix
entr presto
envconsul prips
epic5 procyon-decompiler
eprover profanity
epubcheck proftpd
eralchemy proj
erlang prometheus
erlang@20 proteinortho
erlang@21 protobuf
eslint protobuf-c
esptool protobuf-swift
etcd protobuf@3.6
ethereum proxytunnel
ettercap pspg
evince psqlodbc
exa pulledpork
exempi pulseaudio
exiftool pulumi
exim pumba
exiv2 pure-ftpd
expat pushpin
exploitdb putty
faas-cli puzzles
fabric pwntools
fastjar pwsafe
faudio pybind11
fauna-shell pyenv
fb-client pygobject3
fd pyinstaller
fdroidserver pypy
feedgnuplot pypy3
feh pyqt
ffmpeg pyside
ffmpeg@2.8 python-markdown
ffsend python@2
fibjs pyvim
file-roller qalculate-gtk
findutils qca
fio qemu
firebase-cli qmmp
flac qpdf
flake8 qpid-proton
flashrom qrupdate
flawfinder qscintilla2
flintrock qsoas
flow qt
flowgrind quantlib
fluid-synth r
fluxctl rabbitmq
flyway rabbitmq-c
fn radare2
folly rakudo
fontforge range-v3
fonttools rc
fossil rclone
fpp rdesktop
fq re-flex
fragroute re2
freediameter rebar3
freeipmi recon-ng
freeradius-server redex
frpc redo
frps redsocks
frugal remarshal
fs-uae remctl
fselect rename
fstrm reop
fuse-emulator repo
fuse-zip reposurgeon
futhark rex
fwup riff
gambit-scheme ripgrep
gammu rke
gatsby-cli rmlint
gauche robot-framework
gauge rom-tools
gcc root
gcsfuse roswell
gdal rpm
gdcm rpm2cpio
gdk-pixbuf rsyslog
gdl rtags
gdub ruby
geant4 ruby-build
gearman ruby@2.4
geckodriver ruby@2.5
gedit rush
geographiclib rust
geoipupdate rustup-init
geoserver s-lang
gerbil-scheme s-nail
get_iplayer s2geometry
getdns s3-backer
getmail s3ql
getxbook s6
ghc sagittarius-scheme
ghex saldl
ghr salt
gibo sane-backends
gifski saxon
ginac sbcl
git sblim-sfcc
git-absorb sbt
git-annex scala
git-cola scala@2.12
git-crypt scalapack
git-extras scamper
git-lfs sccache
git-quick-stats scdoc
git-secret schismtracker
git-series scipy
gitbucket scons
gitg scrcpy
gitlab-runner scrypt
gitleaks scw
gitmoji sdhash
gitversion sdl2
gjs sdl2_image
gkrellm sdlpop
glances ser2net
glib-networking serf
glib-openssl serverless
glibmm sf-pwgen
globus-toolkit sflowtool
glooctl shadowsocks-libev
gloox shairport
gmic shairport-sync
gmsh shared-mime-info
gmt shellcheck
gnu-apl shellharden
gnunet shellinabox
gnupg shibboleth-sp
gnupg-pkcs11-scd ship
gnuradio shogun
gnutls siege
go signal-cli
go-bindata sile
go-jira silk
go@1.11 simh
gobby simple-scan
gobject-introspection singular
gocryptfs sip
godep sipsak
golang-migrate siril
goofys sispmctl
gopass sk
goreleaser skaffold
gosu skinny
gpac skopeo
gpgme sleuthkit
gphoto2 slowhttptest
gpsim slrn
gradle smali
grafana sn0int
grails snakemake
grakn snapcraft
graph-tool sngrep
graphene snort
graphicsmagick snownews
grok socat
groonga sofia-sip
groovy softhsm
groovysdk solarus
grpc solr
grpcurl sonarqube
gsettings-desktop-schemas sonarqube-lts
gsl sonobuoy
gsmartcontrol source-highlight
gsoap sourcekitten
gspell sourcery
gst-editing-services spdlog
gst-libav spdylay
gst-plugins-bad speedtest-cli
gst-plugins-base sphinx
gst-plugins-good sphinx-doc
gst-plugins-ugly spice-gtk
gst-python spim
gst-rtsp-server spin
gst-validate spiped
gstreamer spirv-cross
gstreamermm sqlcipher
gtk+3 sqldiff
gtk-doc sqlite-analyzer
gtk-vnc sqlmap
gtkmm squashfs
gtkmm3 squid
gtksourceview4 src
gtksourceviewmm srt
gtksourceviewmm3 ssh-audit
gtmess ssh-permit-a38
gtranslator sshfs
gwenhywfar sshguard
gwyddion ssldump
h2o sslsplit
h3 sstp-client
hadolint stanford-parser
hadoop stella
hapi-fhir-cli step
haproxy stolon
harfbuzz stone-soup
hashcat storm
hashpump stow
haskell-stack streamlink
hbase stress-ng
hebcal strongswan
heimdal stunnel
helmfile stuntman
helmsman subnetcalc
help2man subversion
hfstospell subversion@1.8
hidapi suil
highlight suite-sparse
hive sundials
hledger supervisor
hlint svgo
homebank svtplay-dl
hqx swagger-codegen
htpdate swagger-codegen@2
http_load swaks
httpd swi-prolog
httperf swift-protobuf
httpie swiftformat
httping swiftlint
httrack swig
hub sylpheed
hugo sync_gateway
hydra syncthing
hyperfine synfig
hyperkit sysbench
hyperscan sysdig
hypre tag
i2p talloc
i2pd tarantool
i386-elf-gcc tarsnap
i386-elf-gdb taskell
i386-elf-grub tcl-tk
icarus-verilog tcpdump
icecast tcpflow
icecream tdlib
idris tealdeer
ike-scan tectonic
imagemagick telegraf
imagemagick@6 telegram-cli
imageoptim-cli teleport
imap-uw template-glib
imapfilter termius
inlets terraform
innotop terraform-inventory
insect terraformer
interactive-rebase-tool terragrunt
intercal terrahub
internetarchive tesseract
ios-sim testdisk
ios-webkit-debug-proxy thors-serializer
iperf thrift
iperf3 tika
ipfs tile38
ipmitool tinc
ipopt tintin
ipv6calc tiny-fugue
ipython tinyxml2
ircd-hybrid tmate
ircii tmpreaper
irssi tmux
iso-codes todoman
ispc tomcat
istioctl tomcat-native
isync tomcat@7
janet tomcat@8
jdupes tomee-plus
jena tomee-webprofile
jenkins topgit
jenkins-lts topgrade
jfrog-cli-go tor
jhipster tox
jing-trang traefik
jinja2-cli trafficserver
jlog transcrypt
john-jumbo translate-shell
joplin translate-toolkit
jose triton
jpeg-turbo ttyd
jruby tunnel
jsdoc3 tvnamer
jsoncpp twarc
jsonnet twemcache
jsonrpc-glib twine-pypi
juise txr
juju typescript
jvgrep u-boot-tools
k3d ucloud
k6 udunits
kafka uftp
kafkacat unbound
kahip ungit
kakoune unrar
kibana unrtf
kim-api unshield
knot unzip
kobalt upscaledb
kops uptimed
kore urh
kotlin uriparser
krakend uwsgi
krb5 v8
ktlint vala
kube-aws valabind
kubecfg valgrind
kubectx vapoursynth
kubernetes-cli vapoursynth-imwri
kubernetes-helm vapoursynth-ocr
kubernetes-service-catalog-client vapoursynth-sub
kubeseal varnish
kubespy vault
kustomize vault-cli
kvazaar vaulted
lablgtk vegeta
lammps velero
landscaper verilator
languagetool vert.x
lasso vfuse
lastpass-cli vgmstream
launchdns vifm
lazygit vim
lcm vim@7.4
ldapvi vimpc
ldc vips
ldid virgil
ldns visp
lean-cli vit
ledger vitetris
lego vmtouch
lf vnstat
lftp volatility
lgogdownloader vte3
libarchive vtk
libbitcoin vttest
libbitcoin-blockchain vulkan-headers
libbitcoin-client wabt
libbitcoin-consensus wandio
libbitcoin-database watchexec
libbitcoin-explorer watchman
libbitcoin-network watson
libbitcoin-node wcslib
libbitcoin-protocol wdc
libbitcoin-server webdis
libbluray webpack
libcouchbase websocat
libdap webtorrent-cli
libdazzle weechat
libdvbpsi wgetpaste
libevhtp whois
libewf widelands
libexosip wine
libfaketime winetricks
libfreefare wireguard-go
libftdi wireguard-tools
libgcrypt wiremock-standalone
libgda wireshark
libgee wla-dx
libgig wolfssl
libgit2 wp-cli
libglademm wskdeploy
libgnomecanvasmm wtf
libheif wxmac
libimagequant wxmaxima
libimobiledevice x11vnc
libiodbc x265
libiscsi x3270
libjson-rpc-cpp xa
libjwt xapian
liblcf xcodegen
libmaa xdot
libmatio xmake
libmodbus xml-security-c
libmowgli xml-tooling-c
libmxml xmount
libmypaint xmrig
liboauth xonsh
libogg xorriso
libomp xrootd
libopendkim xsimd
libopenmpt xtensor
libosinfo xxhash
libosip yamllint
libosmium yank
libp11 yapf
libpeas yarn
libphonenumber yash
libpqxx yaws
libpulsar yaz
libqalculate ydcv
libraw yelp-tools
librdkafka ykman
libre yosys
librealsense you-get
librsvg youtube-dl
librsync z3
libsbol zabbix
libsecret zabbix-cli
libsigc++ zbackup
libsignal-protocol-c zboy
libslax zelda-roth-se
libsoup zig
libssh zim
libstatgrab zimg
libstrophe zint
libtasn1 znc
libtensorflow zola
libtins zsdx
libtorrent-rasterbar zstd
libtrace zsxd
libu2f-host
==> Renamed Formulae
confluent-oss -> confluent-platform transmission -> transmission-cli
==> Deleted Formulae
cclive libguess packetbeat
cherokee liblacewing percona-server-mongodb
csup libopkele pincaster
ctunnel llvm@3.9 postgres-xc
engine_pkcs11 llvm@5 skipfish
frag_find lysp taisei
freetds@0.91 mongodb thc-pptp-bruter
ftimes mongodb@3.0 tlsdate
httest mongodb@3.2 tn5250
irods mongodb@3.4 voms
konoha mongodb@3.6 xar-mackyle
kontena mysql-cluster
libggz nordugrid-arc
==> Installing dependencies for postgresql: openssl@1.1 and readline
==> Installing postgresql dependency: openssl@1.1
==> Downloading https://homebrew.bintray.com/bottles/openssl@1.1-1.1.1d.mojave.b
==> Downloading from https://akamai.bintray.com/10/104ef018b7bb8fcc49f57e5a60359
######################################################################## 100.0%
==> Pouring openssl@1.1-1.1.1d.mojave.bottle.tar.gz
==> Caveats
A CA file has been bootstrapped using certificates from the system
keychain. To add additional certificates, place .pem files in
/usr/local/etc/openssl@1.1/certs
and run
/usr/local/opt/openssl@1.1/bin/c_rehash
openssl@1.1 is keg-only, which means it was not symlinked into /usr/local,
because openssl/libressl is provided by macOS so don't link an incompatible version.
If you need to have openssl@1.1 first in your PATH run:
echo 'export PATH="/usr/local/opt/openssl@1.1/bin:$PATH"' >> ~/.zshrc
For compilers to find openssl@1.1 you may need to set:
export LDFLAGS="-L/usr/local/opt/openssl@1.1/lib"
export CPPFLAGS="-I/usr/local/opt/openssl@1.1/include"
==> Summary
🍺 /usr/local/Cellar/openssl@1.1/1.1.1d: 7,983 files, 17.9MB
==> Installing postgresql dependency: readline
==> Downloading https://homebrew.bintray.com/bottles/readline-8.0.1.mojave.bottl
==> Downloading from https://akamai.bintray.com/3c/3c754391e9d243835811d128771ca
######################################################################## 100.0%
==> Pouring readline-8.0.1.mojave.bottle.tar.gz
==> Caveats
readline is keg-only, which means it was not symlinked into /usr/local,
because macOS provides the BSD libedit library, which shadows libreadline.
In order to prevent conflicts when programs look for libreadline we are
defaulting this GNU Readline installation to keg-only.
For compilers to find readline you may need to set:
export LDFLAGS="-L/usr/local/opt/readline/lib"
export CPPFLAGS="-I/usr/local/opt/readline/include"
==> Summary
🍺 /usr/local/Cellar/readline/8.0.1: 48 files, 1.5MB
==> Installing postgresql
==> Downloading https://homebrew.bintray.com/bottles/postgresql-11.5_1.mojave.bo
==> Downloading from https://akamai.bintray.com/46/463c6a192a0b6a5d1359b68db2400
######################################################################## 100.0%
==> Pouring postgresql-11.5_1.mojave.bottle.tar.gz
==> /usr/local/Cellar/postgresql/11.5_1/bin/initdb --locale=C -E UTF-8 /usr/loca
==> Caveats
To migrate existing data from a previous major version of PostgreSQL run:
brew postgresql-upgrade-database
To have launchd start postgresql now and restart at login:
brew services start postgresql
Or, if you don't want/need a background service you can just run:
pg_ctl -D /usr/local/var/postgres start
==> Summary
🍺 /usr/local/Cellar/postgresql/11.5_1: 3,189 files, 35.4MB
==> `brew cleanup` has not been run in 30 days, running now...
Removing: /Users/path/Library/Caches/Homebrew/argon2--20171227.mojave.bottle.tar.gz... (487KB)
Removing: /Users/path/Library/Caches/Homebrew/aspell--0.60.6.1_1.mojave.bottle.1.tar.gz... (113.1MB)
Removing: /Users/path/Library/Caches/Homebrew/curl-openssl--7.65.1.mojave.bottle.tar.gz... (1MB)
Removing: /Users/path/Library/Caches/Homebrew/freetds--1.1.6.mojave.bottle.tar.gz... (3.0MB)
Removing: /Users/path/Library/Caches/Homebrew/freetype--2.10.0.mojave.bottle.tar.gz... (883.9KB)
Removing: /Users/path/Library/Caches/Homebrew/glib--2.60.4_1.mojave.bottle.tar.gz... (4.4MB)
Removing: /Users/path/Library/Caches/Homebrew/jemalloc--5.2.0.mojave.bottle.tar.gz... (606.0KB)
Removing: /Users/path/Library/Caches/Homebrew/libev--4.25.mojave.bottle.tar.gz... (140.7KB)
Removing: /Users/path/Library/Caches/Homebrew/libevent--2.1.10.mojave.bottle.tar.gz... (782.3KB)
Removing: /Users/path/Library/Caches/Homebrew/libpq--11.3.mojave.bottle.tar.gz... (5.4MB)
Removing: /Users/path/Library/Caches/Homebrew/libzip--1.5.2.mojave.bottle.tar.gz... (113.2KB)
Removing: /Users/path/Library/Caches/Homebrew/mysql--8.0.16.mojave.bottle.tar.gz... (73MB)
Removing: /Users/path/Library/Caches/Homebrew/nghttp2--1.39.1.mojave.bottle.tar.gz... (949.6KB)
Removing: /Users/path/Library/Caches/Homebrew/openldap--2.4.47.mojave.bottle.tar.gz... (2.7MB)
Removing: /Users/path/Library/Caches/Homebrew/openssl--1.0.2s.mojave.bottle.tar.gz... (3.7MB)
Removing: /Users/path/Library/Caches/Homebrew/php--7.3.6_1.mojave.bottle.tar.gz... (19.9MB)
Removing: /Users/path/Library/Caches/Homebrew/python--3.7.3.mojave.bottle.1.tar.gz... (14.6MB)
Removing: /Users/path/Library/Caches/Homebrew/re2c--1.1.1.mojave.bottle.tar.gz... (207.3KB)
Removing: /usr/local/Cellar/readline/8.0.0_1... (48 files, 1.5MB)
Removing: /Users/path/Library/Caches/Homebrew/readline--8.0.0_1.mojave.bottle.tar.gz... (517.7KB)
Removing: /Users/path/Library/Caches/Homebrew/sqlite--3.28.0.mojave.bottle.tar.gz... (1.8MB)
Removing: /Users/path/Library/Caches/Homebrew/unixodbc--2.3.7.mojave.bottle.tar.gz... (564.5KB)
Removing: /Users/path/Library/Caches/Homebrew/webp--1.0.2.mojave.bottle.1.tar.gz... (863.4KB)
Removing: /Users/path/Library/Logs/Homebrew/tig... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libtiff... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libtool... (64B)
Removing: /Users/path/Library/Logs/Homebrew/jansson... (64B)
Removing: /Users/path/Library/Logs/Homebrew/gmp... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libxml2... (64B)
Removing: /Users/path/Library/Logs/Homebrew/nghttp2... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libpng... (64B)
Removing: /Users/path/Library/Logs/Homebrew/ncurses... (64B)
Removing: /Users/path/Library/Logs/Homebrew/gdbm... (64B)
Removing: /Users/path/Library/Logs/Homebrew/curl-openssl... (64B)
Removing: /Users/path/Library/Logs/Homebrew/bison@2.7... (64B)
Removing: /Users/path/Library/Logs/Homebrew/freetype... (64B)
Removing: /Users/path/Library/Logs/Homebrew/argon2... (64B)
Removing: /Users/path/Library/Logs/Homebrew/rtmpdump... (64B)
Removing: /Users/path/Library/Logs/Homebrew/python... (3 files, 132KB)
Removing: /Users/path/Library/Logs/Homebrew/anyenv... (64B)
Removing: /Users/path/Library/Logs/Homebrew/mhash... (64B)
Removing: /Users/path/Library/Logs/Homebrew/apr-util... (64B)
Removing: /Users/path/Library/Logs/Homebrew/jemalloc... (64B)
Removing: /Users/path/Library/Logs/Homebrew/brotli... (64B)
Removing: /Users/path/Library/Logs/Homebrew/icu4c... (64B)
Removing: /Users/path/Library/Logs/Homebrew/glib... (64B)
Removing: /Users/path/Library/Logs/Homebrew/readline... (64B)
Removing: /Users/path/Library/Logs/Homebrew/webp... (64B)
Removing: /Users/path/Library/Logs/Homebrew/sqlite... (64B)
Removing: /Users/path/Library/Logs/Homebrew/c-ares... (64B)
Removing: /Users/path/Library/Logs/Homebrew/php... (12 files, 2.2KB)
Removing: /Users/path/Library/Logs/Homebrew/xz... (64B)
Removing: /Users/path/Library/Logs/Homebrew/unixodbc... (64B)
Removing: /Users/path/Library/Logs/Homebrew/re2c... (64B)
Removing: /Users/path/Library/Logs/Homebrew/ghq... (64B)
Removing: /Users/path/Library/Logs/Homebrew/freetds... (64B)
Removing: /Users/path/Library/Logs/Homebrew/gettext... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libssh2... (64B)
Removing: /Users/path/Library/Logs/Homebrew/mysql... (950B)
Removing: /Users/path/Library/Logs/Homebrew/mcrypt... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libsodium... (64B)
Removing: /Users/path/Library/Logs/Homebrew/apr... (64B)
Removing: /Users/path/Library/Logs/Homebrew/autoconf... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libpq... (64B)
Removing: /Users/path/Library/Logs/Homebrew/aspell... (64B)
Removing: /Users/path/Library/Logs/Homebrew/tidy-html5... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libevent... (64B)
Removing: /Users/path/Library/Logs/Homebrew/pcre... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libidn... (64B)
Removing: /Users/path/Library/Logs/Homebrew/jpeg... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libzip... (64B)
Removing: /Users/path/Library/Logs/Homebrew/zsh... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libmetalink... (64B)
Removing: /Users/path/Library/Logs/Homebrew/openldap... (64B)
Removing: /Users/path/Library/Logs/Homebrew/openssl... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libev... (64B)
Removing: /Users/path/Library/Logs/Homebrew/peco... (64B)
Removing: /Users/path/Library/Logs/Homebrew/libffi... (64B)
Pruned 1 symbolic links and 2 directories from /usr/local
==> Caveats
==> openssl@1.1
A CA file has been bootstrapped using certificates from the system
keychain. To add additional certificates, place .pem files in
/usr/local/etc/openssl@1.1/certs
and run
/usr/local/opt/openssl@1.1/bin/c_rehash
openssl@1.1 is keg-only, which means it was not symlinked into /usr/local,
because openssl/libressl is provided by macOS so don't link an incompatible version.
If you need to have openssl@1.1 first in your PATH run:
echo 'export PATH="/usr/local/opt/openssl@1.1/bin:$PATH"' >> ~/.zshrc
For compilers to find openssl@1.1 you may need to set:
export LDFLAGS="-L/usr/local/opt/openssl@1.1/lib"
export CPPFLAGS="-I/usr/local/opt/openssl@1.1/include"
==> readline
readline is keg-only, which means it was not symlinked into /usr/local,
because macOS provides the BSD libedit library, which shadows libreadline.
In order to prevent conflicts when programs look for libreadline we are
defaulting this GNU Readline installation to keg-only.
For compilers to find readline you may need to set:
export LDFLAGS="-L/usr/local/opt/readline/lib"
export CPPFLAGS="-I/usr/local/opt/readline/include"
==> postgresql
To migrate existing data from a previous major version of PostgreSQL run:
brew postgresql-upgrade-database
To have launchd start postgresql now and restart at login:
brew services start postgresql
Or, if you don't want/need a background service you can just run:
pg_ctl -D /usr/local/var/postgres start
-> % initdb /usr/local/var/postgres -E utf8
The files belonging to this database system will be owned by user "path".
This user must also own the server process.
The database cluster will be initialized with locale "ja_JP.UTF-8".
initdb: could not find suitable text search configuration for locale "ja_JP.UTF-8"
The default text search configuration will be set to "simple".
Data page checksums are disabled.
initdb: directory "/usr/local/var/postgres" exists but is not empty
If you want to create a new database system, either remove or empty
the directory "/usr/local/var/postgres" or run initdb
with an argument other than "/usr/local/var/postgres".
-> % postgres --version
postgres (PostgreSQL) 11.5
Valet のインストール
-> % composer global require laravel/valet
Changed current directory to /Users/path/.composer
Using version ^2.4 for laravel/valet
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 21 installs, 0 updates, 0 removals
- Installing symfony/polyfill-php72 (v1.12.0): Downloading (100%)
- Installing symfony/polyfill-mbstring (v1.12.0): Downloading (100%)
- Installing symfony/var-dumper (v4.3.4): Downloading (100%)
- Installing tightenco/collect (v6.0.4): Downloading (100%)
- Installing nategood/httpful (0.2.20): Downloading (100%)
- Installing symfony/process (v4.3.4): Downloading (100%)
- Installing psr/container (1.0.0): Downloading (100%)
- Installing php-di/invoker (2.0.0): Downloading (100%)
- Installing symfony/service-contracts (v1.1.6): Downloading (100%)
- Installing symfony/polyfill-php73 (v1.12.0): Downloading (100%)
- Installing symfony/console (v4.3.4): Downloading (100%)
- Installing mnapoli/silly (1.7.1): Downloading (100%)
- Installing symfony/translation-contracts (v1.1.6): Downloading (100%)
- Installing symfony/translation (v4.3.4): Downloading (100%)
- Installing nesbot/carbon (2.24.0): Downloading (100%)
- Installing psr/simple-cache (1.0.1): Downloading (100%)
- Installing illuminate/contracts (v6.0.4): Downloading (100%)
- Installing doctrine/inflector (v1.3.0): Downloading (100%)
- Installing illuminate/support (v6.0.4): Downloading (100%)
- Installing illuminate/container (v6.0.4): Downloading (100%)
- Installing laravel/valet (v2.4.2): Downloading (100%)
symfony/service-contracts suggests installing symfony/service-implementation
symfony/console suggests installing symfony/event-dispatcher
symfony/console suggests installing symfony/lock
symfony/console suggests installing psr/log (For using the console logger)
symfony/translation suggests installing symfony/config
symfony/translation suggests installing symfony/yaml
illuminate/support suggests installing illuminate/filesystem (Required to use the composer class (^6.0).)
illuminate/support suggests installing moontoast/math (Required to use ordered UUIDs (^1.1).)
illuminate/support suggests installing ramsey/uuid (Required to use Str::uuid() (^3.7).)
illuminate/support suggests installing vlucas/phpdotenv (Required to use the Env class and env helper (^3.3).)
Writing lock file
Generating autoload files
-> % echo 'export PATH=~/.composer/vendor/bin:$PATH' >> ~/.zshrc
-> % source ~/.zshrc
-> % valet install
Password:
Stopping nginx...
Installing nginx...
[nginx] is not installed, installing it now via Brew... 🍻
Installing nginx configuration...
Installing nginx directory...
Updating PHP configuration...
Restarting php...
Installing dnsmasq...
[dnsmasq] is not installed, installing it now via Brew... 🍻
Restarting dnsmasq...
Valet is configured to serve for TLD [.test]
Restarting nginx...
Valet installed successfully!
Laravel アプリケーションの起動
-> % mkdir ~/Projects/laravel-app
-> % cd ~/Projects/laravel-app
-> % valet park
Password:
This directory has been added to Valet's paths.
-> % composer create-project laravel/laravel sample
Installing laravel/laravel (v6.0.2)
- Installing laravel/laravel (v6.0.2): Downloading (100%)
Created project in sample
> @php -r "file_exists('.env') || copy('.env.example', '.env');"
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 84 installs, 0 updates, 0 removals
- Installing symfony/polyfill-ctype (v1.12.0): Downloading (100%)
- Installing phpoption/phpoption (1.5.0): Downloading (100%)
- Installing vlucas/phpdotenv (v3.6.0): Downloading (100%)
- Installing symfony/css-selector (v4.3.4): Downloading (100%)
- Installing tijsverkoyen/css-to-inline-styles (2.2.1): Downloading (100%)
- Installing symfony/polyfill-php72 (v1.12.0): Loading from cache
- Installing symfony/polyfill-mbstring (v1.12.0): Loading from cache
- Installing symfony/var-dumper (v4.3.4): Loading from cache
- Installing symfony/routing (v4.3.4): Downloading (100%)
- Installing symfony/process (v4.3.4): Loading from cache
- Installing symfony/polyfill-php73 (v1.12.0): Loading from cache
- Installing symfony/polyfill-intl-idn (v1.12.0): Downloading (100%)
- Installing symfony/mime (v4.3.4): Downloading (100%)
- Installing symfony/http-foundation (v4.3.4): Downloading (100%)
- Installing symfony/event-dispatcher-contracts (v1.1.5): Downloading (100%)
- Installing psr/container (1.0.0): Loading from cache
- Installing symfony/event-dispatcher (v4.3.4): Downloading (100%)
- Installing psr/log (1.1.0): Downloading (100%)
- Installing symfony/debug (v4.3.4): Downloading (100%)
- Installing symfony/http-kernel (v4.3.4): Downloading (100%)
- Installing symfony/finder (v4.3.4): Downloading (100%)
- Installing symfony/service-contracts (v1.1.6): Loading from cache
- Installing symfony/console (v4.3.4): Loading from cache
- Installing symfony/polyfill-iconv (v1.12.0): Downloading (100%)
- Installing doctrine/lexer (1.1.0): Downloading (100%)
- Installing egulias/email-validator (2.1.11): Downloading (100%)
- Installing swiftmailer/swiftmailer (v6.2.1): Downloading (100%)
- Installing paragonie/random_compat (v9.99.99): Downloading (100%)
- Installing ramsey/uuid (3.8.0): Downloading (100%)
- Installing psr/simple-cache (1.0.1): Loading from cache
- Installing opis/closure (3.4.0): Downloading (100%)
- Installing symfony/translation-contracts (v1.1.6): Loading from cache
- Installing symfony/translation (v4.3.4): Loading from cache
- Installing nesbot/carbon (2.24.0): Loading from cache
- Installing monolog/monolog (2.0.0): Downloading (100%)
- Installing league/flysystem (1.0.55): Downloading (100%)
- Installing erusev/parsedown (1.7.3): Downloading (100%)
- Installing dragonmantank/cron-expression (v2.3.0): Downloading (100%)
- Installing doctrine/inflector (v1.3.0): Loading from cache
- Installing laravel/framework (v6.0.4): Downloading (100%)
- Installing fideloper/proxy (4.2.1): Downloading (100%)
- Installing jakub-onderka/php-console-color (v0.2): Downloading (100%)
- Installing jakub-onderka/php-console-highlighter (v0.4): Downloading (100%)
- Installing dnoegel/php-xdg-base-dir (0.1): Downloading (100%)
- Installing nikic/php-parser (v4.2.4): Downloading (100%)
- Installing psy/psysh (v0.9.9): Downloading (100%)
- Installing laravel/tinker (v1.0.10): Downloading (100%)
- Installing scrivo/highlight.php (v9.15.10.0): Downloading (100%)
- Installing filp/whoops (2.5.0): Downloading (100%)
- Installing facade/ignition-contracts (1.0.0): Downloading (100%)
- Installing facade/flare-client-php (1.1.0): Downloading (100%)
- Installing facade/ignition (1.9.0): Downloading (100%)
- Installing fzaninotto/faker (v1.8.0): Downloading (100%)
- Installing hamcrest/hamcrest-php (v2.0.0): Downloading (100%)
- Installing mockery/mockery (1.2.3): Downloading (100%)
- Installing nunomaduro/collision (v3.0.1): Downloading (100%)
- Installing sebastian/version (2.0.1): Downloading (100%)
- Installing sebastian/type (1.1.3): Downloading (100%)
- Installing sebastian/resource-operations (2.0.1): Downloading (100%)
- Installing sebastian/object-reflector (1.1.1): Downloading (100%)
- Installing sebastian/recursion-context (3.0.0): Downloading (100%)
- Installing sebastian/object-enumerator (3.0.3): Downloading (100%)
- Installing sebastian/global-state (3.0.0): Downloading (100%)
- Installing sebastian/exporter (3.1.2): Downloading (100%)
- Installing sebastian/environment (4.2.2): Downloading (100%)
- Installing sebastian/diff (3.0.2): Downloading (100%)
- Installing sebastian/comparator (3.0.2): Downloading (100%)
- Installing phpunit/php-timer (2.1.2): Downloading (100%)
- Installing phpunit/php-text-template (1.2.1): Downloading (100%)
- Installing phpunit/php-file-iterator (2.0.2): Downloading (100%)
- Installing phpunit/php-token-stream (3.1.1): Downloading (100%)
- Installing theseer/tokenizer (1.1.3): Downloading (100%)
- Installing sebastian/code-unit-reverse-lookup (1.0.1): Downloading (100%)
- Installing phpunit/php-code-coverage (7.0.8): Downloading (100%)
- Installing webmozart/assert (1.5.0): Downloading (100%)
- Installing phpdocumentor/reflection-common (2.0.0): Downloading (100%)
- Installing phpdocumentor/type-resolver (1.0.1): Downloading (100%)
- Installing phpdocumentor/reflection-docblock (4.3.2): Downloading (100%)
- Installing doctrine/instantiator (1.2.0): Downloading (100%)
- Installing phpspec/prophecy (1.8.1): Downloading (100%)
- Installing phar-io/version (2.0.1): Downloading (100%)
- Installing phar-io/manifest (1.0.3): Downloading (100%)
- Installing myclabs/deep-copy (1.9.3): Downloading (100%)
- Installing phpunit/phpunit (8.3.5): Downloading (100%)
symfony/routing suggests installing symfony/config (For using the all-in-one router or any loader)
symfony/routing suggests installing symfony/yaml (For using the YAML loader)
symfony/routing suggests installing symfony/expression-language (For using expression matching)
symfony/routing suggests installing doctrine/annotations (For using the annotation loader)
symfony/event-dispatcher-contracts suggests installing psr/event-dispatcher
symfony/event-dispatcher suggests installing symfony/dependency-injection
symfony/http-kernel suggests installing symfony/browser-kit
symfony/http-kernel suggests installing symfony/config
symfony/http-kernel suggests installing symfony/dependency-injection
symfony/service-contracts suggests installing symfony/service-implementation
symfony/console suggests installing symfony/lock
swiftmailer/swiftmailer suggests installing true/punycode (Needed to support internationalized email addresses, if ext-intl is not installed)
paragonie/random_compat suggests installing ext-libsodium (Provides a modern crypto API that can be used to generate random bytes.)
ramsey/uuid suggests installing ircmaxell/random-lib (Provides RandomLib for use with the RandomLibAdapter)
ramsey/uuid suggests installing ext-libsodium (Provides the PECL libsodium extension for use with the SodiumRandomGenerator)
ramsey/uuid suggests installing ext-uuid (Provides the PECL UUID extension for use with the PeclUuidTimeGenerator and PeclUuidRandomGenerator)
ramsey/uuid suggests installing moontoast/math (Provides support for converting UUID to 128-bit integer (in string form).)
ramsey/uuid suggests installing ramsey/uuid-doctrine (Allows the use of Ramsey\Uuid\Uuid as Doctrine field type.)
ramsey/uuid suggests installing ramsey/uuid-console (A console application for generating UUIDs with ramsey/uuid)
symfony/translation suggests installing symfony/config
symfony/translation suggests installing symfony/yaml
monolog/monolog suggests installing graylog2/gelf-php (Allow sending log messages to a GrayLog2 server)
monolog/monolog suggests installing doctrine/couchdb (Allow sending log messages to a CouchDB server)
monolog/monolog suggests installing ruflin/elastica (Allow sending log messages to an Elastic Search server)
monolog/monolog suggests installing elasticsearch/elasticsearch (Allow sending log messages to an Elasticsearch server via official client)
monolog/monolog suggests installing php-amqplib/php-amqplib (Allow sending log messages to an AMQP server using php-amqplib)
monolog/monolog suggests installing ext-amqp (Allow sending log messages to an AMQP server (1.0+ required))
monolog/monolog suggests installing ext-mongodb (Allow sending log messages to a MongoDB server (via driver))
monolog/monolog suggests installing mongodb/mongodb (Allow sending log messages to a MongoDB server (via library))
monolog/monolog suggests installing aws/aws-sdk-php (Allow sending log messages to AWS services like DynamoDB)
monolog/monolog suggests installing rollbar/rollbar (Allow sending log messages to Rollbar)
monolog/monolog suggests installing php-console/php-console (Allow sending log messages to Google Chrome)
league/flysystem suggests installing league/flysystem-eventable-filesystem (Allows you to use EventableFilesystem)
league/flysystem suggests installing league/flysystem-rackspace (Allows you to use Rackspace Cloud Files)
league/flysystem suggests installing league/flysystem-azure (Allows you to use Windows Azure Blob storage)
league/flysystem suggests installing league/flysystem-webdav (Allows you to use WebDAV storage)
league/flysystem suggests installing league/flysystem-aws-s3-v2 (Allows you to use S3 storage with AWS SDK v2)
league/flysystem suggests installing league/flysystem-aws-s3-v3 (Allows you to use S3 storage with AWS SDK v3)
league/flysystem suggests installing spatie/flysystem-dropbox (Allows you to use Dropbox storage)
league/flysystem suggests installing srmklive/flysystem-dropbox-v2 (Allows you to use Dropbox storage for PHP 5 applications)
league/flysystem suggests installing league/flysystem-cached-adapter (Flysystem adapter decorator for metadata caching)
league/flysystem suggests installing league/flysystem-sftp (Allows you to use SFTP server storage via phpseclib)
league/flysystem suggests installing league/flysystem-ziparchive (Allows you to use ZipArchive adapter)
laravel/framework suggests installing ext-memcached (Required to use the memcache cache driver.)
laravel/framework suggests installing ext-redis (Required to use the Redis cache and queue drivers.)
laravel/framework suggests installing aws/aws-sdk-php (Required to use the SQS queue driver, DynamoDb failed job storage and SES mail driver (^3.0).)
laravel/framework suggests installing doctrine/dbal (Required to rename columns and drop SQLite columns (^2.6).)
laravel/framework suggests installing guzzlehttp/guzzle (Required to use the Mailgun mail driver and the ping methods on schedules (^6.0).)
laravel/framework suggests installing league/flysystem-aws-s3-v3 (Required to use the Flysystem S3 driver (^1.0).)
laravel/framework suggests installing league/flysystem-cached-adapter (Required to use the Flysystem cache (^1.0).)
laravel/framework suggests installing league/flysystem-sftp (Required to use the Flysystem SFTP driver (^1.0).)
laravel/framework suggests installing moontoast/math (Required to use ordered UUIDs (^1.1).)
laravel/framework suggests installing pda/pheanstalk (Required to use the beanstalk queue driver (^4.0).)
laravel/framework suggests installing pusher/pusher-php-server (Required to use the Pusher broadcast driver (^3.0).)
laravel/framework suggests installing symfony/cache (Required to PSR-6 cache bridge (^4.3.4).)
laravel/framework suggests installing symfony/psr-http-message-bridge (Required to use PSR-7 bridging features (^1.2).)
laravel/framework suggests installing wildbit/swiftmailer-postmark (Required to use Postmark mail driver (^3.0).)
psy/psysh suggests installing ext-pdo-sqlite (The doc command requires SQLite to work.)
psy/psysh suggests installing hoa/console (A pure PHP readline implementation. You'll want this if your PHP install doesn't already support readline or libedit.)
filp/whoops suggests installing whoops/soap (Formats errors as SOAP responses)
facade/ignition suggests installing laravel/telescope (^2.0)
sebastian/global-state suggests installing ext-uopz (*)
phpunit/php-code-coverage suggests installing ext-xdebug (^2.7.2)
phpunit/phpunit suggests installing phpunit/php-invoker (^2.0.0)
phpunit/phpunit suggests installing ext-xdebug (*)
Writing lock file
Generating optimized autoload files
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
> @php artisan package:discover --ansi
Discovered Package: facade/ignition
Discovered Package: fideloper/proxy
Discovered Package: laravel/tinker
Discovered Package: nesbot/carbon
Discovered Package: nunomaduro/collision
Package manifest generated successfully.
> @php artisan key:generate --ansi
Application key set successfully.
http://sample.test にアクセスするとブラウザからアプリを確認できます。
ブラウザからアプリを確認ができれば、ValetでLaravel環境構築の終了です。
参考情報
こちらの記事を参考に環境構築を実施しました。