Page MenuHomeDevCentral

No OneTemporary

diff --git a/roles/devserver/userland-software/files/install-php-extension.sh b/roles/devserver/userland-software/files/install-php-extension.sh
index 426e97b..39128e9 100644
--- a/roles/devserver/userland-software/files/install-php-extension.sh
+++ b/roles/devserver/userland-software/files/install-php-extension.sh
@@ -1,15 +1,17 @@
#!/bin/sh
# -------------------------------------------------------------
# Intall PHP extension
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# Author: Sébastien Santoro aka Dereckson
# Created: 2018-03-29
# License: BSD-2-Clause
# Source file: roles/devserver/userland-software/files/install-php-extension.sh
# -------------------------------------------------------------
-phpize
-./configure
-make
+AS_BUILDER=sudo -u builder
+
+$AS_BUILDER phpize
+$AS_BUILDER ./configure
+$AS_BUILDER make
diff --git a/roles/devserver/userland-software/php-ast.sls b/roles/devserver/userland-software/php-ast.sls
index ee322e1..4e2717b 100644
--- a/roles/devserver/userland-software/php-ast.sls
+++ b/roles/devserver/userland-software/php-ast.sls
@@ -1,48 +1,47 @@
# -------------------------------------------------------------
# Salt — Provision dev software
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# Created: 2018-03-29
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
{% from "roles/devserver/userland-software/map.jinja" import php with context %}
# -------------------------------------------------------------
# Fetch software
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
/opt/php-ast:
file.directory:
- user: builder
php_ast_repository:
git.latest:
- name: https://github.com/nikic/php-ast.git
- target: /opt/php-ast
- user: builder
# -------------------------------------------------------------
# Build software
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
php_ast_build:
cmd.script:
- source: salt://roles/devserver/userland-software/files/install-php-extension.sh
- cwd: /opt/php-ast
- - runas: builder
- creates: /opt/php-ast/modules/ast.so
php_ast_install:
cmd.run:
- name: make install
- cwd: /opt/php-ast
- creates: {{ php.extension_dir }}/ast.so
# -------------------------------------------------------------
# PHP configuration
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
{{ php.cli_conf_dir }}/ext-40-ast.ini:
file.managed:
- source: salt://roles/devserver/userland-software/files/ast.ini

File Metadata

Mime Type
text/x-diff
Expires
Thu, Sep 18, 03:38 (6 h, 32 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2989932
Default Alt Text
(2 KB)

Event Timeline