summaryrefslogtreecommitdiff
path: root/debian/rhimportd.pre
blob: a97f474d38e95e1cbc5561068ecddfdb6ba917d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh
#
# create some directories needed by rhimportd
# this would normally be done by the initscript.
#

if [ -n "$RHIMPORTD_TEMP_DIR" ]; then
  mkdir -m 775 -p "$RHIMPORTD_TEMP_DIR"
  chown rhimportd:rhimportd "$RHIMPORTD_TEMP_DIR"
fi

if [ -n "$RHIMPORTD_LOCAL_FETCH_DIR" ]; then
  mkdir -m 775 -p "$RHIMPORTD_LOCAL_FETCH_DIR"
  chown rhimportd:rhimportd "$RHIMPORTD_LOCAL_FETCH_DIR"
fi

if [ -n "$RHIMPORTD_WATCH_DIR" ]; then
  mkdir -m 775 -p "$RHIMPORTD_WATCH_DIR"
  chown rhimportd:rhimportd "$RHIMPORTD_WATCH_DIR"
fi

exit 0