mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-20 12:33:40 -04:00
sys-cluster/nova: units, tmpfile, logrotate
Signed-off-by: Alessandro Barbieri <lssndrbarbieri@gmail.com>
This commit is contained in:
7
sys-cluster/nova/files/nova.logrotate
Normal file
7
sys-cluster/nova/files/nova.logrotate
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
/var/log/nova/*.log {
|
||||||
|
daily
|
||||||
|
missingok
|
||||||
|
compress
|
||||||
|
delaycompress
|
||||||
|
copytruncate
|
||||||
|
}
|
||||||
1
sys-cluster/nova/files/nova.tmpfile
Normal file
1
sys-cluster/nova/files/nova.tmpfile
Normal file
@@ -0,0 +1 @@
|
|||||||
|
d /run/nova 0755 nova nova -
|
||||||
15
sys-cluster/nova/files/openstack-nova-api.service
Normal file
15
sys-cluster/nova/files/openstack-nova-api.service
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova API Server
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=notify
|
||||||
|
NotifyAccess=all
|
||||||
|
TimeoutStartSec=0
|
||||||
|
Restart=always
|
||||||
|
User=nova
|
||||||
|
ExecStart=/usr/bin/nova-api --log-file /var/log/nova/api.log
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
||||||
16
sys-cluster/nova/files/openstack-nova-compute.service
Normal file
16
sys-cluster/nova/files/openstack-nova-compute.service
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova Compute Server
|
||||||
|
After=syslog.target network.target libvirtd.service virtqemud.service
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Environment=LIBGUESTFS_ATTACH_METHOD=appliance
|
||||||
|
Type=notify
|
||||||
|
NotifyAccess=all
|
||||||
|
TimeoutStartSec=0
|
||||||
|
Restart=always
|
||||||
|
User=nova
|
||||||
|
ExecStart=/usr/bin/nova-compute --log-file /var/log/nova/compute.log
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
||||||
15
sys-cluster/nova/files/openstack-nova-conductor.service
Normal file
15
sys-cluster/nova/files/openstack-nova-conductor.service
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova Conductor Server
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=notify
|
||||||
|
NotifyAccess=all
|
||||||
|
TimeoutStartSec=0
|
||||||
|
Restart=always
|
||||||
|
User=nova
|
||||||
|
ExecStart=/usr/bin/nova-conductor --log-file /var/log/nova/conductor.log
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
||||||
15
sys-cluster/nova/files/openstack-nova-metadata-api.service
Normal file
15
sys-cluster/nova/files/openstack-nova-metadata-api.service
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova Metadata API Server
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=notify
|
||||||
|
NotifyAccess=all
|
||||||
|
TimeoutStartSec=0
|
||||||
|
Restart=always
|
||||||
|
User=nova
|
||||||
|
ExecStart=/usr/bin/nova-api-metadata --log-file /var/log/nova/metadata.log
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
||||||
13
sys-cluster/nova/files/openstack-nova-novncproxy.service
Normal file
13
sys-cluster/nova/files/openstack-nova-novncproxy.service
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova NoVNC Proxy Server
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=simple
|
||||||
|
User=nova
|
||||||
|
EnvironmentFile=-/etc/conf.d/openstack-nova-novncproxy
|
||||||
|
ExecStart=/usr/bin/nova-novncproxy --web /usr/share/webapps/novnc/ --log-file /var/log/nova/novnc.log $OPTIONS
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
14
sys-cluster/nova/files/openstack-nova-os-compute-api.service
Normal file
14
sys-cluster/nova/files/openstack-nova-os-compute-api.service
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova Compute API Server
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=notify
|
||||||
|
NotifyAccess=all
|
||||||
|
TimeoutStartSec=0
|
||||||
|
Restart=always
|
||||||
|
User=nova
|
||||||
|
ExecStart=/usr/bin/nova-api-os-compute --log-file /var/log/nova/api-os-compute.log
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
15
sys-cluster/nova/files/openstack-nova-scheduler.service
Normal file
15
sys-cluster/nova/files/openstack-nova-scheduler.service
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=OpenStack Nova Scheduler Server
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=notify
|
||||||
|
NotifyAccess=all
|
||||||
|
TimeoutStartSec=0
|
||||||
|
Restart=always
|
||||||
|
User=nova
|
||||||
|
ExecStart=/usr/bin/nova-scheduler --log-file /var/log/nova/scheduler.log
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
|
||||||
@@ -6,7 +6,7 @@ EAPI=8
|
|||||||
MYP="${P//_/}"
|
MYP="${P//_/}"
|
||||||
PYTHON_COMPAT=( python3_{8..9} )
|
PYTHON_COMPAT=( python3_{8..9} )
|
||||||
|
|
||||||
inherit bash-completion-r1 distutils-r1 linux-info udev
|
inherit bash-completion-r1 distutils-r1 linux-info systemd tmpfiles udev
|
||||||
|
|
||||||
DESCRIPTION="Cloud computing fabric controller"
|
DESCRIPTION="Cloud computing fabric controller"
|
||||||
HOMEPAGE="
|
HOMEPAGE="
|
||||||
@@ -196,13 +196,13 @@ python_compile_all() {
|
|||||||
python_install_all() {
|
python_install_all() {
|
||||||
distutils-r1_python_install_all
|
distutils-r1_python_install_all
|
||||||
|
|
||||||
if use !compute-only; then
|
for svc in api compute conductor consoleauth network novncproxy scheduler spicehtml5proxy xvpvncproxy; do
|
||||||
for svc in api conductor consoleauth network scheduler spicehtml5proxy xvpvncproxy; do
|
newinitd "${FILESDIR}/nova.initd" "nova-${svc}"
|
||||||
newinitd "${FILESDIR}/nova.initd" "nova-${svc}"
|
done
|
||||||
done
|
|
||||||
fi
|
for svc in api compute conductor metadata-api novncproxy os-compute-api scheduler; do
|
||||||
use compute && newinitd "${FILESDIR}/nova.initd" "nova-compute"
|
systemd_dounit "${FILESDIR}/openstack-nova-${svc}.service"
|
||||||
use novncproxy && newinitd "${FILESDIR}/nova.initd" "nova-novncproxy"
|
done
|
||||||
|
|
||||||
diropts -m 0750 -o nova -g qemu
|
diropts -m 0750 -o nova -g qemu
|
||||||
dodir /var/log/nova /var/lib/nova/instances
|
dodir /var/log/nova /var/lib/nova/instances
|
||||||
@@ -229,6 +229,11 @@ python_install_all() {
|
|||||||
|
|
||||||
newbashcomp tools/nova-manage.bash_completion nova-manage
|
newbashcomp tools/nova-manage.bash_completion nova-manage
|
||||||
|
|
||||||
|
newtmpfiles "${FILESDIR}/nova.tmpfile" nova.conf
|
||||||
|
|
||||||
|
insinto /etc/logrotate.d
|
||||||
|
newins "${FILESDIR}/nova.logrotate" nova.conf
|
||||||
|
|
||||||
if use iscsi ; then
|
if use iscsi ; then
|
||||||
# Install udev rules for handle iscsi disk with right links under /dev
|
# Install udev rules for handle iscsi disk with right links under /dev
|
||||||
udev_newrules "${FILESDIR}/openstack-scsi-disk.rules" 60-openstack-scsi-disk.rules
|
udev_newrules "${FILESDIR}/openstack-scsi-disk.rules" 60-openstack-scsi-disk.rules
|
||||||
Reference in New Issue
Block a user