Reputation: 694
I'm trying to set up my config.yaml such that I can use PHP's ImageMagick library immediately after performing a vagrant up. Currently the only way I can get it to work is by installing all the packages manually after booting the server and SSH'ing in. When trying to install via vagrant up, it installs the packages, but PHP doesn't recognize the library for whatever reason.
I'm using Vagrant 1.8.4.
Here's the relevant configurations I did in my config.yaml:
Server Config
server:
install: '1'
packages:
- vim
- htop
- git
- tmux
- pv
- imagemagick
PHP Config
php:
install: '1'
settings:
version: '55'
modules:
php:
- cli
- cgi
- intl
- imagick
pear: { }
pecl: { }
ini:
engine=On: '0'
engine: 'On'
short_open_tag: 'On' # We still use this in some places; also (bad) libraries might use this
asp_tags: 'Off'
precision: '14'
output_buffering: '4096'
zlib.output_compression: 'Off'
implicit_flush: 'Off'
serialize_precision: '17'
disable_functions: 'pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_│+ wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,'
zend.enable_gc: 'On'
expose_php: 'On'
max_execution_time: '30'
max_input_time: '60'
memory_limit: 128M
error_reporting: 'E_ALL & ~E_DEPRECATED & ~E_NOTICE & ~E_WARNING'
display_errors: 'Off' # Only turn on in personal VM
display_startup_errors: 'Off' # Only turn on in personal VM
log_errors: 'On'
log_errors_max_len: '1024'
error_log: /var/log/php/php.log # We have to log errors to a place that has write permissions for www-user (Apache user)
ignore_repeated_errors: 'Off'
ignore_repeated_source: 'Off'
report_memleaks: 'On'
track_errors: 'Off'
html_errors: 'On'
variables_order: GPCS
request_order: GP
register_argc_argv: 'Off'
auto_globals_jit: 'On'
post_max_size: 8M
default_mimetype: text/html
enable_dl: 'Off'
file_uploads: 'On'
upload_max_filesize: 2M
max_file_uploads: '20'
allow_url_fopen: 'On'
allow_url_include: 'Off'
default_socket_timeout: '60'
cli_server.color: 'On'
SMTP: localhost
smtp_port: '25'
mail.add_x_header: 'On'
sql.safe_mode: 'Off'
odbc.allow_persistent: 'On'
odbc.check_persistent: 'On'
odbc.max_persistent: '-1'
odbc.max_links: '-1'
odbc.defaultlrl: '4096'
odbc.defaultbinmode: '1'
ibase.allow_persistent: '1'
ibase.max_persistent: '-1'
ibase.max_links: '-1'
ibase.timestampformat: '%Y-%m-%d %H:%M:%S'
ibase.dateformat: '%Y-%m-%d'
session.save_handler: files
session.use_cookies: '1'
Any help is greatly appreciated.
Upvotes: 1
Views: 833
Reputation: 694
Just for reference, it turned out we were installing php5-imagick instead of php5.6-imagick, which made a huge difference. I'm not sure why installing via apt-get handled this difference better.
Upvotes: 1