Sha256: 25b145b4ca2c5e9b267d60f5ff460b4ed4799606ae7b11e274a1f01c600c0c9e
Contents?: true
Size: 713 Bytes
Versions: 4
Compression:
Stored size: 713 Bytes
Contents
#!/bin/bash <% if options.swap -%> # allocate swap space fallocate -l <%= options.swap %> /swapfile chmod 0600 /swapfile mkswap /swapfile echo 10 > /proc/sys/vm/swappiness swapon /swapfile echo 1 > /proc/sys/vm/overcommit_memory <% end -%> <% if options.prepare -%> <% if procfile.size > 1 -%> # If running the production procfile then create or migrate existing database if [ "${*}" == "foreman start --procfile=Procfile.prod" ]; then <% else -%> # If running the rails server then create or migrate existing database if [ "${*}" == "./bin/rails server" ]; then <% end -%> ./bin/rails <%= dbprep_command %> fi <% elsif !options.swap -%> # Add any container initialization steps here <% end -%> exec "${@}"
Version data entries
4 entries across 4 versions & 1 rubygems