Site Tools


Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
php:macos-installation [2021-10-28] dcaiphp:macos-installation [2021-10-31] (current) dcai
Line 1: Line 1:
 ===== PHP 7.4 macOS installation ===== ===== PHP 7.4 macOS installation =====
  
 +
 +==== install packages ====
 <code> <code>
-brew install php@7.4 nginx+brew install php@7.4 nginx postgresql@12
 # pecl install zip libsodium # pecl install zip libsodium
 # remove duplicated extension added in /usr/local/etc/php/7.4/php.ini # remove duplicated extension added in /usr/local/etc/php/7.4/php.ini
 +brew link php@7.4
 +brew link postgresql@12
 +</code>
 +
 +
 +==== setup postgres ====
 +<code>
 +# init db
 +initdb -D /Users/dcai/.local/var/postgres12
 +# start db
 +postgres -D ~/.local/var/postgres12/
 +echo "ALTER USER postgres WITH PASSWORD 'postgres';" | psql -U postgres
 </code> </code>
  
php/macos-installation.1635424326.txt.gz · Last modified: by dcai