Browse Source

first commit

postgres
root 12 years ago
commit
83e8435113
  1. 10
      precise/base-0k/hooks/install
  2. 3
      precise/base-0k/hooks/start
  3. 3
      precise/base-0k/hooks/stop
  4. 5
      precise/base-0k/metadata.yaml
  5. 1
      precise/base-0k/revision
  6. 13
      precise/minecraft/etc/init/minecraft.conf
  7. 7
      precise/minecraft/hooks/TODO
  8. 17
      precise/minecraft/hooks/install
  9. 2
      precise/minecraft/hooks/start
  10. 2
      precise/minecraft/hooks/stop
  11. 7
      precise/minecraft/metadata.yaml
  12. 1
      precise/minecraft/revision

10
precise/base-0k/hooks/install

@ -0,0 +1,10 @@
#!/bin/bash
set -eux # -x for verbose logging to juju debug-log
apt-get -y install syslog-ng bash-completion wget bzip2 git-core less language-pack-en python-software-properties tmux sudo
juju-log "Finished Successfully installed base !"

3
precise/base-0k/hooks/start

@ -0,0 +1,3 @@
#!/bin/bash
juju-log "Nothing to Start for base."

3
precise/base-0k/hooks/stop

@ -0,0 +1,3 @@
#!/bin/bash
juju-log "Nothing to stop for base."

5
precise/base-0k/metadata.yaml

@ -0,0 +1,5 @@
name: base-0k
summary: "Base 0k"
maintainer: "Valentin Lab <valentin.lab@kalysto.org>"
description: |
Installs the base common 0k system.

1
precise/base-0k/revision

@ -0,0 +1 @@
0

13
precise/minecraft/etc/init/minecraft.conf

@ -0,0 +1,13 @@
# Minecraft upstart
# this script will start/stop Minecraft
description "Minecraft Server"
version "1.0"
author "Marco Ceppi"
env CPU_COUNT=8
env JAVA_ARGS="-Xmx1024M -Xms1024M -XX:+UseConcMarkSweepGC -XX:+CMSIncrementalPacing -XX:+AggressiveOpts"
env LOG="/var/log/minecraft_server.log"
chdir /opt/apps/minecraft
exec java $JAVA_ARGS -XX:ParallelGCThreads=$CPU_COUNT -jar minecraft_server.jar nogui >> $LOG 2>&1

7
precise/minecraft/hooks/TODO

@ -0,0 +1,7 @@
- minecraft upstart:
NB_CPU should be an option
- upgrade charm
- options

17
precise/minecraft/hooks/install

@ -0,0 +1,17 @@
#!/bin/bash
set -eux # -x for verbose logging to juju debug-log
## Using headless to avoid installing X server ;)
apt-get -y install openjdk-7-jre-headless
INSTALL_DIR=/opt/apps/minecraft
mkdir -p $INSTALL_DIR
wget https://s3.amazonaws.com/MinecraftDownload/launcher/minecraft_server.jar -O $INSTALL8DIR/minecraft_server.jar
cp etc/init/minecraft /etc/init/minecraft

2
precise/minecraft/hooks/start

@ -0,0 +1,2 @@
#!/bin/bash

2
precise/minecraft/hooks/stop

@ -0,0 +1,2 @@
#!/bin/bash

7
precise/minecraft/metadata.yaml

@ -0,0 +1,7 @@
name: minecraft
summary: "Minecraft"
maintainer: "Valentin Lab <valentin.lab@kalysto.org>"
inherit: base
data-dir:
description: |
Installs minecraft.

1
precise/minecraft/revision

@ -0,0 +1 @@
0
Loading…
Cancel
Save