You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/custom-boot-hooks/index.md
+12-13Lines changed: 12 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,11 +1,11 @@
1
1
---
2
-
title: Add Custom Boot Hook to /opt/jrc/hooks/boot.d
2
+
title: Add Custom Boot Hook to /mnt/jrc-comms/hooks/boot.d
3
3
---
4
4
5
-
This guide explains how to add a custom boot hook to `/opt/jrc/hooks/boot.d/` in applications that execute scripts in numerical order. Follow these steps to ensure proper execution order and functionality.
5
+
This guide explains how to add a custom boot hook to `/mnt/jrc-comms/hooks/boot.d/` in applications that execute scripts in numerical order. Follow these steps to ensure proper execution order and functionality.
6
6
7
7
!!! Assumption:
8
-
We assume you have root access to modify files in `/opt/jrc/hooks/boot.d/`.
8
+
We assume you have root access to modify files in `/mnt/jrc-comms/hooks/boot.d/`.
9
9
!!!
10
10
11
11
## Create Custom Boot Hook
@@ -15,15 +15,14 @@ Create a new shell script with a filename starting with `99-` (to ensure it runs
15
15
16
16
```bash
17
17
#!/bin/bash
18
-
/opt/jrc/hooks/boot.d/99-custom-task
18
+
/mnt/jrc-comms/hooks/boot.d/99-custom-task
19
19
20
20
echo"Running custom boot task..."
21
21
```
22
22
23
23
### 2. Set Permissions and Ownership
24
24
Make the script executable and ensure it’s owned by `root`:
25
25
26
-
27
26
### 3. Verify Execution Order
28
27
The application runs scripts in ascending order based on their numeric prefixes. For example:
29
28
@@ -43,7 +42,7 @@ To log system time at the end of the boot process:
0 commit comments