Rework parts, add compilation of pyc
This commit is contained in:
parent
7a802bbf2e
commit
2e75d5cd33
291
snapcraft.yaml
291
snapcraft.yaml
|
@ -1,5 +1,5 @@
|
||||||
name: microstack
|
name: microstack
|
||||||
version: alpha
|
version: rocky
|
||||||
summary: Openstack on your laptop.
|
summary: Openstack on your laptop.
|
||||||
description: |
|
description: |
|
||||||
Microstack gives you an easy way to develop and test Openstack
|
Microstack gives you an easy way to develop and test Openstack
|
||||||
|
@ -298,62 +298,26 @@ apps:
|
||||||
- network-bind
|
- network-bind
|
||||||
|
|
||||||
parts:
|
parts:
|
||||||
# Keystone
|
# OpenStack Python Projects, keyed off Keystone
|
||||||
keystone:
|
openstack-projects:
|
||||||
plugin: python
|
plugin: python
|
||||||
python-version: python2
|
python-version: python2
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
||||||
source: http://tarballs.openstack.org/keystone/keystone-stable-rocky.tar.gz
|
source: http://tarballs.openstack.org/keystone/keystone-stable-rocky.tar.gz
|
||||||
python-packages:
|
|
||||||
- mysql-python
|
|
||||||
- oslo.cache[dogpile]
|
|
||||||
- pymysql
|
|
||||||
- pysqlite
|
|
||||||
- uwsgi
|
|
||||||
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
|
||||||
build-packages:
|
|
||||||
- gcc
|
|
||||||
- libffi-dev
|
|
||||||
- libmysqlclient-dev
|
|
||||||
- libssl-dev
|
|
||||||
- libsqlite3-dev
|
|
||||||
|
|
||||||
configure-the-things:
|
|
||||||
plugin: dump
|
|
||||||
source: src/experiments
|
|
||||||
|
|
||||||
keystone-config:
|
|
||||||
after: [keystone]
|
|
||||||
plugin: dump
|
|
||||||
source: http://tarballs.openstack.org/keystone/keystone-stable-rocky.tar.gz
|
|
||||||
organize:
|
|
||||||
etc/*.conf: etc/keystone/
|
|
||||||
etc/*.ini: etc/keystone/
|
|
||||||
etc/*.json: etc/keystone/
|
|
||||||
etc/*.templates: etc/keystone/
|
|
||||||
|
|
||||||
filesets:
|
|
||||||
etc:
|
|
||||||
- etc/keystone/*.conf
|
|
||||||
- etc/keystone/*.ini
|
|
||||||
- etc/keystone/*.json
|
|
||||||
- etc/keystone/*.templates
|
|
||||||
stage: [$etc]
|
|
||||||
prime: [$etc]
|
|
||||||
|
|
||||||
# Nova
|
|
||||||
nova:
|
|
||||||
after: [keystone] # We abitrarily rely on keystone to be the one to patch things
|
|
||||||
plugin: python
|
|
||||||
python-version: python2
|
|
||||||
source: http://tarballs.openstack.org/nova/nova-stable-rocky.tar.gz
|
|
||||||
python-packages:
|
python-packages:
|
||||||
- libvirt-python
|
- libvirt-python
|
||||||
|
- oslo.cache[dogpile]
|
||||||
- pymysql
|
- pymysql
|
||||||
- uwsgi
|
- uwsgi
|
||||||
- python-memcached
|
|
||||||
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
- http://tarballs.openstack.org/nova/nova-stable-rocky.tar.gz
|
||||||
|
- http://tarballs.openstack.org/neutron/neutron-stable-rocky.tar.gz
|
||||||
|
- http://tarballs.openstack.org/glance/glance-stable-rocky.tar.gz
|
||||||
|
- http://tarballs.openstack.org/cinder/cinder-stable-rocky.tar.gz
|
||||||
|
- http://tarballs.openstack.org/horizon/horizon-stable-rocky.tar.gz
|
||||||
|
- python-cinderclient
|
||||||
|
- python-openstackclient
|
||||||
|
- python-swiftclient
|
||||||
build-packages:
|
build-packages:
|
||||||
- gcc
|
- gcc
|
||||||
- libffi-dev
|
- libffi-dev
|
||||||
|
@ -365,37 +329,43 @@ parts:
|
||||||
- conntrack
|
- conntrack
|
||||||
- coreutils
|
- coreutils
|
||||||
- qemu-utils
|
- qemu-utils
|
||||||
|
- haproxy
|
||||||
|
override-prime: |
|
||||||
|
snapcraftctl prime
|
||||||
|
# Now that everything is built, let's disable user site-packages
|
||||||
|
# as stated in PEP-0370
|
||||||
|
sed -i usr/lib/python2.7/site.py -e 's/^ENABLE_USER_SITE = None$/ENABLE_USER_SITE = False/'
|
||||||
|
# This is the last step, let's now compile all our pyc files.
|
||||||
|
./usr/bin/python2.7 -m compileall .
|
||||||
|
|
||||||
|
keystone-config:
|
||||||
|
after: [openstack-projects]
|
||||||
|
plugin: dump
|
||||||
|
source: http://tarballs.openstack.org/keystone/keystone-stable-rocky.tar.gz
|
||||||
|
organize:
|
||||||
|
etc/*.conf: etc/keystone/
|
||||||
|
etc/*.ini: etc/keystone/
|
||||||
|
etc/*.json: etc/keystone/
|
||||||
|
etc/*.templates: etc/keystone/
|
||||||
|
|
||||||
|
filesets:
|
||||||
|
etc:
|
||||||
|
- etc/keystone/*
|
||||||
|
stage: [$etc]
|
||||||
|
prime: [$etc]
|
||||||
|
|
||||||
nova-config:
|
nova-config:
|
||||||
after: [nova]
|
after: [openstack-projects]
|
||||||
plugin: dump
|
plugin: dump
|
||||||
source: http://tarballs.openstack.org/nova/nova-stable-rocky.tar.gz
|
source: http://tarballs.openstack.org/nova/nova-stable-rocky.tar.gz
|
||||||
filesets:
|
filesets:
|
||||||
etc:
|
etc:
|
||||||
- etc/nova/*.conf
|
- etc/nova/*
|
||||||
- etc/nova/*.ini
|
|
||||||
- etc/nova/*.json
|
|
||||||
- etc/nova/rootwrap.d
|
|
||||||
stage: [$etc]
|
stage: [$etc]
|
||||||
prime: [$etc]
|
prime: [$etc]
|
||||||
|
|
||||||
neutron:
|
|
||||||
after: [keystone] # We arbitrarily rely on keystone to patch some things
|
|
||||||
plugin: python
|
|
||||||
python-version: python2
|
|
||||||
source: http://tarballs.openstack.org/neutron/neutron-stable-rocky.tar.gz
|
|
||||||
python-packages:
|
|
||||||
- pymysql
|
|
||||||
- python-memcached
|
|
||||||
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
|
||||||
build-packages:
|
|
||||||
- gcc
|
|
||||||
- libffi-dev
|
|
||||||
- libssl-dev
|
|
||||||
|
|
||||||
neutron-config:
|
neutron-config:
|
||||||
after: [neutron]
|
after: [openstack-projects]
|
||||||
plugin: dump
|
plugin: dump
|
||||||
source: http://tarballs.openstack.org/neutron/neutron-stable-rocky.tar.gz
|
source: http://tarballs.openstack.org/neutron/neutron-stable-rocky.tar.gz
|
||||||
organize:
|
organize:
|
||||||
|
@ -409,37 +379,8 @@ parts:
|
||||||
stage: [$etc]
|
stage: [$etc]
|
||||||
prime: [$etc]
|
prime: [$etc]
|
||||||
|
|
||||||
neutron-dependencies:
|
|
||||||
after: [neutron]
|
|
||||||
plugin: nil
|
|
||||||
stage-packages:
|
|
||||||
- haproxy
|
|
||||||
|
|
||||||
# Glance
|
|
||||||
glance:
|
|
||||||
after: [keystone] # We arbitrarily rely on keystone to patch some things
|
|
||||||
plugin: python
|
|
||||||
python-version: python2
|
|
||||||
source: http://tarballs.openstack.org/glance/glance-stable-rocky.tar.gz
|
|
||||||
python-packages:
|
|
||||||
- httplib2
|
|
||||||
- os-brick
|
|
||||||
- oslo.rootwrap
|
|
||||||
- oslo.vmware
|
|
||||||
- pymysql
|
|
||||||
- python-cinderclient
|
|
||||||
- python-memcached
|
|
||||||
- python-swiftclient
|
|
||||||
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
|
||||||
build-packages:
|
|
||||||
- gcc
|
|
||||||
- libffi-dev
|
|
||||||
- libssl-dev
|
|
||||||
- libxml2-dev
|
|
||||||
- libxslt1-dev
|
|
||||||
glance-config:
|
glance-config:
|
||||||
after: [glance]
|
after: [openstack-projects]
|
||||||
plugin: dump
|
plugin: dump
|
||||||
source: http://tarballs.openstack.org/glance/glance-stable-rocky.tar.gz
|
source: http://tarballs.openstack.org/glance/glance-stable-rocky.tar.gz
|
||||||
organize:
|
organize:
|
||||||
|
@ -448,9 +389,34 @@ parts:
|
||||||
etc/*.json: etc/glance/
|
etc/*.json: etc/glance/
|
||||||
filesets:
|
filesets:
|
||||||
etc:
|
etc:
|
||||||
- etc/glance/*.conf
|
- etc/glance/*
|
||||||
- etc/glance/*.ini
|
stage: [$etc]
|
||||||
- etc/glance/*.json
|
prime: [$etc]
|
||||||
|
|
||||||
|
cinder-config:
|
||||||
|
after: [cinder]
|
||||||
|
plugin: dump
|
||||||
|
source: http://tarballs.openstack.org/cinder/cinder-stable-rocky.tar.gz
|
||||||
|
organize:
|
||||||
|
etc/*.conf: etc/cinder/
|
||||||
|
etc/*.ini: etc/cinder/
|
||||||
|
etc/*.json: etc/cinder/
|
||||||
|
etc/*.templates: etc/cinder/
|
||||||
|
filesets:
|
||||||
|
etc:
|
||||||
|
- etc/cinder/*
|
||||||
|
stage: [$etc]
|
||||||
|
prime: [$etc]
|
||||||
|
|
||||||
|
horizon-config:
|
||||||
|
after: [openstack-projects]
|
||||||
|
plugin: dump
|
||||||
|
source: http://tarballs.openstack.org/horizon/horizon-stable-rocky.tar.gz
|
||||||
|
organize:
|
||||||
|
etc/*.conf: etc/horizon/
|
||||||
|
filesets:
|
||||||
|
etc:
|
||||||
|
- etc/horizon/*
|
||||||
stage: [$etc]
|
stage: [$etc]
|
||||||
prime: [$etc]
|
prime: [$etc]
|
||||||
|
|
||||||
|
@ -501,26 +467,6 @@ parts:
|
||||||
after:
|
after:
|
||||||
- openvswitch
|
- openvswitch
|
||||||
|
|
||||||
# Openstack Shared Parts
|
|
||||||
templates:
|
|
||||||
after:
|
|
||||||
- keystone-config
|
|
||||||
- nova-config
|
|
||||||
- neutron-config
|
|
||||||
- glance-config
|
|
||||||
- ovs-wrapper
|
|
||||||
- qemu
|
|
||||||
- kvm-support
|
|
||||||
- libvirt
|
|
||||||
- mysql-server
|
|
||||||
- rabbitmq-server
|
|
||||||
- memcached
|
|
||||||
- cinder-config
|
|
||||||
- horizon-config
|
|
||||||
- python-openstackclient
|
|
||||||
plugin: dump
|
|
||||||
source: snap
|
|
||||||
|
|
||||||
nginx:
|
nginx:
|
||||||
after: [keystone, nova, neutron, openvswitch]
|
after: [keystone, nova, neutron, openvswitch]
|
||||||
source: http://www.nginx.org/download/nginx-1.13.0.tar.gz
|
source: http://www.nginx.org/download/nginx-1.13.0.tar.gz
|
||||||
|
@ -642,7 +588,6 @@ parts:
|
||||||
# * is not used to avoid directory merge conflicts
|
# * is not used to avoid directory merge conflicts
|
||||||
snap/microstack/current/: ./
|
snap/microstack/current/: ./
|
||||||
|
|
||||||
|
|
||||||
# MySQL
|
# MySQL
|
||||||
mysql-server:
|
mysql-server:
|
||||||
plugin: dump
|
plugin: dump
|
||||||
|
@ -671,7 +616,7 @@ parts:
|
||||||
rabbitmq-defaults: usr/lib/rabbitmq/lib/rabbitmq_server-3.5.7/sbin/rabbitmq-defaults
|
rabbitmq-defaults: usr/lib/rabbitmq/lib/rabbitmq_server-3.5.7/sbin/rabbitmq-defaults
|
||||||
erl: usr/bin/erl
|
erl: usr/bin/erl
|
||||||
|
|
||||||
# Memcached
|
# Memcached Token Caching
|
||||||
memcached:
|
memcached:
|
||||||
plugin: autotools
|
plugin: autotools
|
||||||
source: https://memcached.org/files/memcached-1.5.10.tar.gz
|
source: https://memcached.org/files/memcached-1.5.10.tar.gz
|
||||||
|
@ -684,7 +629,7 @@ parts:
|
||||||
make
|
make
|
||||||
make install
|
make install
|
||||||
|
|
||||||
# Cinder
|
# Cinder LVM backend
|
||||||
lvm2:
|
lvm2:
|
||||||
source: http://www.sourceware.org/pub/lvm2/releases/LVM2.2.02.172.tgz
|
source: http://www.sourceware.org/pub/lvm2/releases/LVM2.2.02.172.tgz
|
||||||
plugin: autotools
|
plugin: autotools
|
||||||
|
@ -692,78 +637,8 @@ parts:
|
||||||
- --with-confdir=/var/snap/common/etc/
|
- --with-confdir=/var/snap/common/etc/
|
||||||
- --with-default-system-dir=/var/snap/common/etc/
|
- --with-default-system-dir=/var/snap/common/etc/
|
||||||
build-attributes: [no-patchelf]
|
build-attributes: [no-patchelf]
|
||||||
cinder:
|
|
||||||
after: [keystone]
|
|
||||||
plugin: python
|
|
||||||
python-version: python2
|
|
||||||
source: http://tarballs.openstack.org/cinder/cinder-stable-rocky.tar.gz
|
|
||||||
python-packages:
|
|
||||||
- python-memcached
|
|
||||||
- pymysql
|
|
||||||
- uwsgi
|
|
||||||
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
|
||||||
build-packages:
|
|
||||||
- gcc
|
|
||||||
- libffi-dev
|
|
||||||
- libssl-dev
|
|
||||||
- libxml2-dev
|
|
||||||
- libxslt1-dev
|
|
||||||
cinder-config:
|
|
||||||
after: [cinder]
|
|
||||||
plugin: dump
|
|
||||||
source: http://tarballs.openstack.org/cinder/cinder-stable-rocky.tar.gz
|
|
||||||
organize:
|
|
||||||
etc/*.conf: etc/cinder/
|
|
||||||
etc/*.ini: etc/cinder/
|
|
||||||
etc/*.json: etc/cinder/
|
|
||||||
etc/*.templates: etc/cinder/
|
|
||||||
filesets:
|
|
||||||
etc:
|
|
||||||
- etc/cinder/*.conf
|
|
||||||
- etc/cinder/*.ini
|
|
||||||
- etc/cinder/*.json
|
|
||||||
- etc/cinder/*.templates
|
|
||||||
stage: [$etc]
|
|
||||||
prime: [$etc]
|
|
||||||
|
|
||||||
# Horizon
|
|
||||||
horizon:
|
|
||||||
after: [keystone]
|
|
||||||
plugin: python
|
|
||||||
python-version: python2
|
|
||||||
source: http://tarballs.openstack.org/horizon/horizon-stable-rocky.tar.gz
|
|
||||||
python-packages:
|
|
||||||
- uwsgi
|
|
||||||
- git+https://github.com/openstack/snap.openstack#egg=snap.openstack
|
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
|
||||||
build-packages:
|
|
||||||
- gcc
|
|
||||||
- libffi-dev
|
|
||||||
- libssl-dev
|
|
||||||
- libxml2-dev
|
|
||||||
- libxslt1-dev
|
|
||||||
horizon-config:
|
|
||||||
after: [horizon]
|
|
||||||
plugin: dump
|
|
||||||
source: http://tarballs.openstack.org/horizon/horizon-stable-rocky.tar.gz
|
|
||||||
organize:
|
|
||||||
etc/*.conf: etc/horizon/
|
|
||||||
filesets:
|
|
||||||
etc:
|
|
||||||
- etc/horizon/*.conf
|
|
||||||
stage: [$etc]
|
|
||||||
prime: [$etc]
|
|
||||||
|
|
||||||
# Openstackclient
|
|
||||||
python-openstackclient:
|
|
||||||
after: [keystone]
|
|
||||||
plugin: python
|
|
||||||
python-version: python2
|
|
||||||
python-packages:
|
|
||||||
- python-openstackclient==3.15.0
|
|
||||||
constraints: https://raw.githubusercontent.com/openstack/requirements/stable/rocky/upper-constraints.txt
|
|
||||||
|
|
||||||
|
# Misc utils for hypervisor networking
|
||||||
bridge-utils:
|
bridge-utils:
|
||||||
source: https://www.kernel.org/pub/linux/utils/net/bridge-utils/bridge-utils-1.6.tar.gz
|
source: https://www.kernel.org/pub/linux/utils/net/bridge-utils/bridge-utils-1.6.tar.gz
|
||||||
plugin: autotools
|
plugin: autotools
|
||||||
|
@ -791,3 +666,27 @@ parts:
|
||||||
- libmnl-dev
|
- libmnl-dev
|
||||||
configflags:
|
configflags:
|
||||||
- "--with-kmod=no"
|
- "--with-kmod=no"
|
||||||
|
|
||||||
|
# Openstack Shared Parts
|
||||||
|
templates:
|
||||||
|
after:
|
||||||
|
- keystone-config
|
||||||
|
- nova-config
|
||||||
|
- neutron-config
|
||||||
|
- glance-config
|
||||||
|
- cinder-config
|
||||||
|
- horizon-config
|
||||||
|
- openvswitch
|
||||||
|
- qemu
|
||||||
|
- kvm-support
|
||||||
|
- libvirt
|
||||||
|
- mysql-server
|
||||||
|
- rabbitmq-server
|
||||||
|
- memcached
|
||||||
|
plugin: dump
|
||||||
|
source: snap
|
||||||
|
|
||||||
|
configure-the-things:
|
||||||
|
plugin: dump
|
||||||
|
source: src/experiments
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue