-
-
Notifications
You must be signed in to change notification settings - Fork 782
Description
Background
In docker-ized environment, there are some use cases that we would like to put all packs, configs and virtualenvs contents baked on the image. Usually st2ctl reload --register-setup-virtualenvs can be used to setup virtualenvs for packs, but this script cannot be used in docker build step because it requires connection to MongoDB and RabbitMQ which does not exist in the image build process.
Suggested solution
I've made a sample script:
https://github.com/shusugmt/st2-docker-pack-prebuild-example/blob/master/setup-pack-virtualenv.py
It would be great if st2 could ship a similar script in /opt/stackstorm/st2/bin or somewhere appropriate.
Before I wrote this script, I've come up with a fairly quick solution that manually activates st2 virtualenv in the build step and then run pip install for each pack, but apparently there are some platform managed dependencies for all packes, so I thought it is better to follow more st2-ish way.