Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F3785510
D3130.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
2 KB
Referenced Files
None
Subscribers
None
D3130.diff
View Options
diff --git a/roles/dbserver-pgsql/server/build.sls b/roles/dbserver-pgsql/server/build.sls
new file mode 100644
--- /dev/null
+++ b/roles/dbserver-pgsql/server/build.sls
@@ -0,0 +1,48 @@
+# -------------------------------------------------------------
+# Salt — PostgreSQL
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+# Project: Nasqueron
+# License: Trivial work, not eligible to copyright
+# -------------------------------------------------------------
+
+{% if grains['os'] == 'FreeBSD' %}
+
+# -------------------------------------------------------------
+# Port options
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+/var/db/ports/databases_postgresql15-server/options:
+ file.managed:
+ - source: salt://roles/devserver/userland-software/files/port_options
+ - template: jinja
+ - mode: 644
+ - context:
+ args:
+ category: databases
+ name: postgresql15-server
+ options:
+ set:
+ - XML
+
+# -------------------------------------------------------------
+# Build and install package
+# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+postgresql_build_dependencies:
+ pkg.installed:
+ - pkgs:
+ - dialog4ports
+ - gmake
+ - pkgconf
+ - gettext
+
+postgresql_build_port:
+ cmd.run:
+ - name: |
+ make build package deinstall reinstall
+ pkg lock {{ port }}
+ - cwd: /usr/ports/databases/postgresql15-server
+ - creates: /usr/local/bin/postgres
+{% endfor %}
+
+{% endif %}
diff --git a/roles/dbserver-pgsql/server/init.sls b/roles/dbserver-pgsql/server/init.sls
--- a/roles/dbserver-pgsql/server/init.sls
+++ b/roles/dbserver-pgsql/server/init.sls
@@ -6,6 +6,7 @@
# -------------------------------------------------------------
include:
+ - .build
- .software
- .config
- .service
diff --git a/roles/dbserver-pgsql/server/software.sls b/roles/dbserver-pgsql/server/software.sls
--- a/roles/dbserver-pgsql/server/software.sls
+++ b/roles/dbserver-pgsql/server/software.sls
@@ -14,7 +14,9 @@
postgresql_server_software:
pkg.installed:
- pkgs:
+ {% if grains['os'] != 'FreeBSD' %}
- {{ packages.postgresql }}
+ {% endif %}
{% if pillar["dbserver_postgresql"]["server"]["with_contrib"] | default(False) %}
- {{ packages["postgresql-contrib"] }}
{% endif %}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 27, 09:03 (21 h, 27 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2266609
Default Alt Text
D3130.diff (2 KB)
Attached To
Mode
D3130: Build PostgreSQL with XML support on FreeBSD
Attached
Detach File
Event Timeline
Log In to Comment