Page MenuHomeDevCentral

No OneTemporary

diff --git a/map.jinja b/map.jinja
index 3a95b5c..c1587b7 100644
--- a/map.jinja
+++ b/map.jinja
@@ -1,57 +1,85 @@
{% set dirs = salt['grains.filter_by']({
'Debian': {
'etc': '/etc',
'bin': '/usr/bin',
'include': '/usr/include',
'lib': '/usr/lib',
'man': '/usr/share/man',
},
'FreeBSD' : {
'etc': '/usr/local/etc',
'bin': '/usr/local/bin',
'include': '/usr/local/include',
'lib': '/usr/local/lib',
'man': '/usr/local/man',
},
}, default='Debian') %}
{% set services = salt['grains.filter_by']({
'Debian': {
'manager': 'systemd',
},
'FreeBSD' : {
'manager': 'rc',
},
}, default='Debian') %}
{% set shells = salt['grains.filter_by']({
'Debian': {
'bash': '/bin/bash',
'fish': '/usr/bin/fish',
'tcsh': '/usr/bin/tcsh',
},
'FreeBSD' : {
'bash': '/usr/local/bin/bash',
'fish': '/usr/local/bin/fish',
'tcsh': '/bin/tcsh',
},
}, default='Debian') %}
{% set packages = salt['grains.filter_by']({
'Debian' : {
+ 'ag': 'silversearcher-ag',
+ 'aspell-fr': 'aspell-fr',
+ 'certbot': 'certbot',
+ 'cppunit': 'libcppunit-dev',
+ 'emacs': 'emacs-nox',
+ 'mariadb': 'mariadb-server',
'sphinx': 'python3-sphinx',
+ 'tcltls': 'tcl-tls',
'varnish': 'varnish',
},
'RedHat': {
+ 'ag': 'the_silver_searcher',
+ 'aspell-fr': 'aspell-fr',
+ 'certbot': 'python2-certbot',
+ 'cppunit': 'cppunit-devel',
+ 'emacs': 'emacs-nox',
+ 'mariadb': 'mariadb-server',
'sphinx': 'python3-sphinx',
+ 'tcltls': 'tcltls',
'varnish': 'varnish',
},
'Arch': {
+ 'ag': 'the_silver_searcher',
+ 'aspell-fr': 'aspell-fr',
+ 'certbot': 'certbot',
+ 'cppunit': 'cppunit',
+ 'emacs': 'emacs-nox',
+ 'mariadb': 'mariadb',
'sphinx': 'python-sphinx',
+ 'tcltls': 'tcltls',
'varnish': 'varnish',
},
'FreeBSD' : {
+ 'ag': 'the_silver_searcher',
+ 'aspell-fr': 'fr-aspell',
+ 'certbot': 'py27-certbot',
+ 'cppunit': 'cppunit',
+ 'emacs': 'emacs-nox11',
+ 'mariadb': 'mariadb101-server',
'sphinx': 'py27-sphinx',
+ 'tcltls': 'tcltls',
'varnish': 'varnish5',
},
}, default='Debian') %}
diff --git a/roles/core/letsencrypt/software.sls b/roles/core/letsencrypt/software.sls
index a1b6399..a4d7054 100644
--- a/roles/core/letsencrypt/software.sls
+++ b/roles/core/letsencrypt/software.sls
@@ -1,40 +1,35 @@
# -------------------------------------------------------------
# Salt — Let's encrypt certificates
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# Created: 2017-04-27
# Description: Provide a renewal service
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
-{% from "map.jinja" import dirs with context %}
+{% from "map.jinja" import dirs, packages with context %}
# -------------------------------------------------------------
# Software
# -------------------------------------------------------------
letsencrypt_software:
pkg.installed:
- {% if grains['os'] == 'FreeBSD' %}
- - name: py27-certbot
- {% else %}
- - name: certbot
- {% endif %}
-
+ - name: {{ packages.certbot }}
# -------------------------------------------------------------
# Working directory
# -------------------------------------------------------------
/var/letsencrypt-auto:
file.directory:
- user: root
- dir_mode: 711
# -------------------------------------------------------------
# Configuration file
# -------------------------------------------------------------
{{ dirs.etc }}/letsencrypt/cli.ini:
file.managed:
- source: salt://roles/core/letsencrypt/files/cli.ini
diff --git a/roles/shellserver/database/mysql.sls b/roles/shellserver/database/mysql.sls
index 304a51c..cd226a5 100644
--- a/roles/shellserver/database/mysql.sls
+++ b/roles/shellserver/database/mysql.sls
@@ -1,33 +1,29 @@
# -------------------------------------------------------------
# Salt — Provision MySQL
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Eglide
# Created: 2017-01-23
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
-{% from "map.jinja" import dirs with context %}
+{% from "map.jinja" import dirs, packages with context %}
# -------------------------------------------------------------
# Software
# -------------------------------------------------------------
mysql:
pkg:
- installed
- pkgs:
- {% if grains['os_family'] == 'Debian' %}
- - mariadb-server
- {% elif grains['os'] == 'FreeBSD' %}
- - mariadb101-server
- {% endif %}
+ - {{ packages.mariadb }}
full_text_search_stopwords_file:
file.managed:
- name: /opt/stopwords.txt
- source: salt://roles/shellserver/database/files/stopwords.txt
mysql_config:
file.managed:
- name: {{ dirs.etc }}/my.cnf
- source: salt://roles/shellserver/database/files/my.cnf
diff --git a/roles/shellserver/userland-software/base.sls b/roles/shellserver/userland-software/base.sls
index 98af362..83261bd 100644
--- a/roles/shellserver/userland-software/base.sls
+++ b/roles/shellserver/userland-software/base.sls
@@ -1,163 +1,149 @@
# -------------------------------------------------------------
# Salt — Provision base software
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Project: Nasqueron
# Created: 2016-04-09
# License: Trivial work, not eligible to copyright
# -------------------------------------------------------------
+{% from "map.jinja" import packages with context %}
+
# -------------------------------------------------------------
# Shells
# -------------------------------------------------------------
shells:
pkg:
- installed
- pkgs:
- bash
- fish
- tcsh
- zsh
# -------------------------------------------------------------
# Editors
#
# Disclaimer: We don't caution the views of Richard Stallman
# or the Church of Emacs positions.
# See http://geekfeminism.wikia.com/wiki/EMACS_virgins_joke
# -------------------------------------------------------------
editors:
pkg:
- installed
- pkgs:
- vim
- nano
- joe
- {% if grains['os_family'] == 'Debian' %}
- - emacs-nox
- {% elif grains['os'] == 'FreeBSD' %}
- - emacs-nox11
- {% endif %}
-
+ - {{ packages.emacs }}
# -------------------------------------------------------------
# General UNIX utilities
# -------------------------------------------------------------
utilities:
pkg:
- installed
- pkgs:
- cmatrix
- figlet
- nmap
- toilet
- tree
- whois
- woof
{% if grains['os_family'] == 'Debian' %}
- bsdmainutils
- sockstat
- dnsutils
- sysvbanner
- toilet-fonts
{% endif %}
{% if grains['os'] == 'FreeBSD' %}
- figlet-fonts
- bind-tools
{% endif %}
# -------------------------------------------------------------
# Development
# -------------------------------------------------------------
dev:
pkg:
- installed
- pkgs:
- autoconf
- automake
- git
- arcanist
- colordiff
- strace
- cmake
- valgrind
+ - {{ packages.cppunit }}
+ - {{ packages.ag }}
{% if grains['os_family'] == 'Debian' %}
- php7.1-curl
- - libcppunit-dev
- - silversearcher-ag
{% endif %}
- {% if grains['os'] == 'FreeBSD' %}
- - cppunit
- - the_silver_searcher
- {% else %}
+ {% if grains['os'] != 'FreeBSD' %}
- clang
- llvm
{% endif %}
dev_popular_libs:
pkg:
- installed
- pkgs:
{% if grains['os_family'] == 'Debian' %}
- libssl-dev
{% endif %}
# -------------------------------------------------------------
# Languages
# -------------------------------------------------------------
languages_removed:
pkg:
- removed
- pkgs:
{% if grains['os_family'] == 'Debian' %}
- php7.0
{% elif grains['os'] == 'FreeBSD' %}
- php70
{% endif %}
languages:
pkg:
- installed
- pkgs:
- python3
{% if grains['os_family'] == 'Debian' %}
- tcl8.6-dev
- php7.1
{% elif grains['os'] == 'FreeBSD' %}
- tcl86
- php71
{% endif %}
# -------------------------------------------------------------
# De facto standard libraries for languages
# -------------------------------------------------------------
languages_libs:
pkg:
- installed
- pkgs:
- tcllib
- {% if grains['os_family'] == 'Debian' %}
- - tcl-tls
- {% elif grains['os'] == 'FreeBSD' %}
- - tcltls
- {% endif %}
+ - {{ packages.tcltls }}
# -------------------------------------------------------------
# Spelling and language utilities
# -------------------------------------------------------------
spelling:
pkg:
- installed
- pkgs:
- verbiste
- {% if grains['os_family'] == 'Debian' %}
- - aspell-fr
- {% elif grains['os'] == 'FreeBSD' %}
- - fr-aspell
- {% endif %}
+ - {{ packages['aspell-fr'] }}

File Metadata

Mime Type
text/x-diff
Expires
Mon, Nov 25, 03:16 (19 h, 23 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2259427
Default Alt Text
(9 KB)

Event Timeline