Introduce src, obj, build, docs & modify Makefile

This commit is contained in:
2018-02-16 15:30:36 +02:00
parent 3a0ccd3b31
commit bd9ebee627
29 changed files with 15 additions and 21 deletions

37
docs/conf/rmps.conf Normal file
View File

@@ -0,0 +1,37 @@
# This is a configuration file for the
# Remote Management and Provisioning Server
#
# NOTE: In order to apply changes, the server
# must be restarted afterwards.
# RMPS DB settings
# db.type=[mysql|postgresql|oracle]
# NOTE: Only "mysql" is implemented so far.
db.type=mysql
db.hostname=127.0.0.1
db.port=3306
db.pass=rmps
# RMPS Core settings
rmps.agent_ip=127.0.0.1
rmps.agent_port=7000
rmps.client_ip=127.0.0.1
rmps.client_port=7001
# Loglevel modes: 1:ERROR,2:WARNING,3:INFO,4:VERBOSE
# The default is 2.
rmps.loglevel=4
rmps.logfile=/home/smirky/projects/rmps/tmp/rmpsd.log
rmps.errlog=/home/smirky/projects/rmps/tmp/rmpsd.err
rmps.pidfile=/home/smirky/projects/rmps/tmp/rmpsd.pid
#rmps.pidfile=/home/smirky/stuff/projects/rmps/rmpsd/rmpsd.pid
# Cryptography settings
rmps.agent_tls_crt=/etc/rmps/certs/server/server.crt
rmps.agent_tls_key=/etc/rmps/certs/server/server.key
rmps.client_tls_crt=/etc/rmps/certs/server/server.crt
rmps.client_tls_key=/etc/rmps/certs/server/server.key
rmps.cafile=/etc/rmps/certs/ca.pem
rmps.cipherlist=ECDHE-RSA-AES128-SHA256:AES256-SHA:RSA
# NFS settings TODO

View File

@@ -0,0 +1,23 @@
# Maintainer: Bogomil Vasilev <smirky@smirky.net>
# Just build via makepkg
pkgname=rmps
pkgver=20180216.0
pkgrel=1
pkgdesc='Remote Management and Provisioning System'
url='https://git.smirky.net/smirky/rmps.git/'
arch=('i686' 'x86_64')
depends=('libmariadbclient')
validpgpkeys=('8C4D267F4977BFFEF23121E8646F3ABF6E457336')
source=("$pkgname::git+https://git.smirky.net/smirky/$pkgname.git")
sha256sums=('SKIP')
build() {
cd "${srcdir}/${pkgname}"
make
}
package() {
cd "${srcdir}/${pkgname}"
make DESTDIR="${pkgdir}" install
}

15
docs/enum_codes Normal file
View File

@@ -0,0 +1,15 @@
# Error codes
100:CONF_DIR_MISSING:"Config directory /etc/rmps is missing!"
101:CONF_DIR_PERM:"Config dir /etc/rmps cannot be accessed, check permissions!"
102:CONF_DIR_NOTDIR:"It appears that /etc/rmps is a file. Should be a directory!"
103:CONF_MISSING:"Config file /etc/rmps/rmps.conf is missing!"
104:CONF_PERM:"Config file /etc/rmps/rmps.conf cannot be accessed, check permissions!"
105:CONF_NOTFILE:"It appears that /etc/rmps/rmps.conf is not a regular file!"
# Warning codes
200:CONF_DIR_GUI_INSECURE:"Insecure group for /etc/rmps. Should be 'rmps'!"
201:CONF_DIR_UID_INSECURE:"Insecure owner for /etc/rmps. Should be 'root'!"
202:CONF_DIR_PERM_INSECURE:"Insecure global permissions for /etc/rmps. Should be 0770!"
203:CONF_FILE_GID_INSECURE:"Insecure group for /etc/rmps/rmps.conf. Should be 'rmps'!"
204:CONF_FILE_UID_INSECURE:"Insecure owner for /etc/rmps/rmps.conf. Should be 'root'!"
205:CONF_FILE_PERM_INSECURE:"Insecure global permissions /etc/rmps/rmps.conf. Shold be 0660!"

View File

@@ -0,0 +1,14 @@
[Unit]
Description=Remote Management and Provisioning Server
After=network.target
[Service]
Type=simple
#PIDFile=/run/rmps/rmpsd.pid
ExecStart=/usr/bin/rmpsd start --daemonize=no
ExecStop=/usr/bin/rmpsd stop
ExecReload=/usr/bin/rmpsd reload
Restart=always
[Install]
WantedBy=multi-user.target