Surprise! We've been running on hardware provided by BuyVM for a few months and wanted to show them a little appreciation.
Running a paste site comes with unique challenges, ones that aren't always obvious and hard to control. As such, BuyVM offered us a home where we could worry less about the hosting side of things and focus on maintaining a clean and useful service! Go check them out and show them some love!
Submitted on December 4, 2014 at 03:38 PM

Section 1 (Text)

pillar data:

database:
  test2:
    sid: test2
    totalMemory: "3000"
  
  beta2:
    sid: beta2
    totalMemory: "3000"

state file:

{% for name, db in pillar.get('database', {}).items()  %}
{{ name }}_gridfo:
  file.managed:
    - name: /srv/grid/{{ name }}_failover.sh
    - source: salt://oracle/blade/grid/failover.sh
    - user: oracle
    - template: jinja
    - mode: 755
{% endfor%}

failover.sh: 

#!/bin/bash

export ORACLE_HOME=/srv/oracle/db/product/12.1.0/dbhome_1
export ORACLE_TOTALMEMORY={{ totalMemory }}