source: src/django_gheat/init_ramdisk.sh@ 11406

Last change on this file since 11406 was 11313, checked in by rick, 12 years ago

The initial ramdisk creation was not an executable script, needed as it is run from cron at boottime.

  • Property svn:executable set to *
File size: 521 bytes
Line 
1#!/bin/sh
2#
3# Quick for building memory disk cache file
4#
5# Meant to be used in crontab like this:
6# @reboot root /usr/local/django_gheat/init_ramdisk.sh
7#
8# Rick van der Zwet <rick@wirelessleiden.nl>
9#
10MD=`mdconfig -a -t malloc -s 1g` || exit 1
11newfs /dev/$MD
12mount -o rw,noatime /dev/$MD /usr/local/var
13mkdir -p /usr/local/var/django/cache/{osm_proxy,tile}
14mkdir -p /usr/local/var/scan-data
15mkdir -p /usr/local/var/httpd/cache/{osmproxy,maps}
16chown -R www:www /usr/local/var/*
17
18/usr/local/etc/rc.d/apache22 restart
Note: See TracBrowser for help on using the repository browser.