Browse Source

chg: renamed ``openerp`` charm to ``0k-openerp``.

postgres
root 11 years ago
parent
commit
3cc64673bb
  1. 0
      precise/0k-openerp/etc/default/openerp-server
  2. 0
      precise/0k-openerp/etc/init.d/openerp-server
  3. 2
      precise/0k-openerp/etc/openerp-server.conf
  4. 43
      precise/0k-openerp/hooks/install
  5. 0
      precise/0k-openerp/hooks/start
  6. 0
      precise/0k-openerp/hooks/stop
  7. 2
      precise/0k-openerp/metadata.yaml
  8. 0
      precise/0k-openerp/revision
  9. 4
      precise/minecraft/hooks/install

0
precise/openerp/etc/default/openerp-server → precise/0k-openerp/etc/default/openerp-server

0
precise/openerp/etc/init.d/openerp-server → precise/0k-openerp/etc/init.d/openerp-server

2
precise/openerp/etc/openerp-server.conf → precise/0k-openerp/etc/openerp-server.conf

@ -3,7 +3,7 @@
; This is the password that allows database operations
; Will be written to by the server when password is changed
; !! Keep this file secure !!
admin_passwd = atptsfOPratcads
admin_passwd = %%PASSWORD%%
root_path = /opt/apps/0k-oe/openobject-server/bin

43
precise/openerp/hooks/install → precise/0k-openerp/hooks/install

@ -3,10 +3,28 @@
set -eux # -x for verbose logging to juju debug-log
#PASSWD=
GIT_BASE=${GIT_BASE:-"git.0k.io:/var/git"}
GIT_CLONE_OPTIONS=""
GIT_CHECKOUT_REF="7.0/0k/dev/master" ## can be a branch, a tag or a commit SHA1
##
## Options (changeable thanks to ``/etc/charm/openerp.conf``)
##
OPENERP_PASSWORD=${OPENERP_PASSWORD:-openerp_password}
## 0k git remote path
GIT_0K_BASE=${GIT_0K_BASE:-"git.0k.io:/var/git"}
## 0k git remote options
GIT_0K_CLONE_OPTIONS=${GIT_0K_CLONE_OPTIONS:-""}
## 0k git-sub setup options
GIT_0K_SUB_SETUP_OPTIONS=${GIT_0K_SUB_SETUP_OPTIONS:-""}
## 0k git default checkout reference (for 0k-oe root package)
GIT_0K_CHECKOUT_REF=${GIT_0K_CHECKOUT_REF:-"7.0/0k/dev/master"}
##
## Code
##
apt-get install sudo libxml2-dev libxslt-dev libpq-dev libyaml-dev \
zlib1g-dev libfreetype6-dev \
@ -30,7 +48,7 @@ fi
#pip install pil
(
cd /tmp &&
scp "$GIT_BASE"/archives/PIL-1.1.7.tar.gz . &&
scp "$GIT_0K_BASE"/archives/PIL-1.1.7.tar.gz . &&
tar xvzf PIL-1.1.7.tar.gz &&
cd PIL-1.1.7 &&
python setup.py install
@ -47,7 +65,7 @@ pip install lxml genshi==0.6 pyparsing==1.5.7 psycopg2 pyyaml reportlab mako \
## download link in PyPi is dead,
## and gna.org was down recently
(
scp "$GIT_BASE/archives/PyChart-1.39.tar.gz" /tmp &&
scp "$GIT_0K_BASE/archives/PyChart-1.39.tar.gz" /tmp &&
cd /tmp && tar xvzf PyChart*.tar.gz &&
cd PyChart* &&
python setup.py install
@ -61,7 +79,7 @@ pip install lxml genshi==0.6 pyparsing==1.5.7 psycopg2 pyyaml reportlab mako \
if ! [ -d "/opt/apps/ooop" ]; then
(
cd /opt/apps &&
git clone $GIT_CLONE_OPTIONS "$GIT_BASE/0k/ooop.git" &&
git clone $GIT_0K_CLONE_OPTIONS "$GIT_0K_BASE/0k/ooop.git" &&
cd /opt/apps/ooop &&
git checkout 0k/prod/master &&
@ -77,17 +95,18 @@ fi
(
cd /opt/apps &&
git clone $GIT_CLONE_OPTIONS "$GIT_BASE"/0k/0k-oe.git &&
git clone $GIT_0K_CLONE_OPTIONS "$GIT_0K_BASE"/0k/0k-oe.git &&
cd /opt/apps/0k-oe &&
git checkout "$GIT_CHECKOUT_REF" &&
git sub setup
git checkout "$GIT_0K_CHECKOUT_REF" &&
git sub setup $GIT_0K_SUB_SETUP_OPTIONS -r
)
adduser --system --home=/var/lib/openerp --group openerp
## XXXvlab: warning password in charm !!
cp -i etc/openerp-server.conf /etc/
sed -ri "s/%%PASSWORD%%/$OPENERP_PASSWORD/g" /etc/openerp-server.conf
cp -i etc/init.d/openerp-server /etc/init.d/
chown openerp /etc/openerp-server.conf
@ -153,7 +172,7 @@ chown openerp .
(
cd /opt/apps &&
git clone $GIT_CLONE_OPTIONS "$GIT_BASE/0k/0k-manage.git" &&
git clone $GIT_0K_CLONE_OPTIONS "$GIT_0K_BASE/0k/0k-manage.git" &&
cd /opt/apps/0k-manage &&
git checkout 0k/prod/master &&

0
precise/openerp/hooks/start → precise/0k-openerp/hooks/start

0
precise/openerp/hooks/stop → precise/0k-openerp/hooks/stop

2
precise/openerp/metadata.yaml → precise/0k-openerp/metadata.yaml

@ -1,4 +1,4 @@
name: openerp
name: 0k-openerp
summary: "OpenERP server"
maintainer: "Valentin Lab <valentin.lab@kalysto.org>"
inherit: python-venv

0
precise/openerp/revision → precise/0k-openerp/revision

4
precise/minecraft/hooks/install

@ -6,7 +6,7 @@ set -eux # -x for verbose logging to juju debug-log
apt-get -y install openjdk-7-jre-headless
## For tectonicus
apt-get -y install subversion
#apt-get -y install subversion
INSTALL_DIR=/opt/apps/minecraft
@ -14,6 +14,6 @@ mkdir -p $INSTALL_DIR
wget https://s3.amazonaws.com/MinecraftDownload/launcher/minecraft_server.jar -O $INSTALL_DIR/minecraft_server.jar
cp etc/init/minecraft /etc/init/minecraft
cp etc/init/minecraft.conf /etc/init/minecraft.conf
Loading…
Cancel
Save