Skip to content

Exec not found when running hook script #64

@bisrael8191

Description

@bisrael8191

Version: Customizer v3.2.3
OS: Linux hostname 3.11.0-20-generic #34~precise1-Ubuntu SMP Thu Apr 3 17:25:07 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

Attempting to run the hook script immediately exits with the following output:

builder@hostname:~$ sudo /opt/Customizer/CLI.sh --hook
[*] Executing hook at: 11:51:59 PM/09-06-2014
[*] Checking filesystem
[*] Checking lock
[*] Checking sources.list
[*] Allwoing local access to X-server
non-network local connections being added to access control list
[*] Mounting: /dev
[*] Mounting: /proc
[*] Mounting: /sys
[*] Mounting: /var/lib/dbus
[*] Mounting: /var/run/dbus
[*] Doing some preparations
[*] Setting up locales
[*] Blocking files
[*] Running command: exec /tmp/HOOK
env: exec: No such file or directory
[!] Chroot has returned exit status
[*] Unblocking files
[*] Cleaning up
[*] Unmounting: /sys
[*] Unmounting: /proc
[*] Unmounting: /dev
[*] Verbose unmounting
[*] Unmounting: /var/lib/dbus
[*] Blocking local access to X-server
non-network local connections being removed from access control list
[*] Finished hook at: 11:52:00 PM/09-06-2014

A test hook script used to reproduce:

#!/bin/bash
echo "HELLO!!"

Settings.conf hook line:

HOOK="/home/base_hook.sh"

Changing line 41 in the hook script to __chroot__ "/tmp/HOOK" solved the issue but may only work for bash scripts. I haven't tried with any other scripts or binary executables.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions