Service wont start on boot
- Dominant language
- Go
- Stars
- 167
- Forks
- 21
- Avg merge
- 58m
- Merged PRs (30d)
- 1
Description
Dear ec2-macos-init contributors,
I've now tried multiple times (directly through launchd and through ec2-macos-init) to run a simple binary on system boot. This aims to join the machine to an Active Directory, etc... What I managed with this config so far was, that the script got executed correctly - but only a few seconds after a (random) user logged in to the machine - not on boot.
The config looks like this:
```
[[Module]]
Name = "SetupStartup"
PriorityGroup = 4
[Module.Command]
Cmd = ["/usr/local/bin/startup.sh.x"]
# I've tried this both with root and ec2-user
RunAsUser = "ec2-user"
```
chmod on the binary is a+x
Contributor guide
Research direction
Reproduce the startup behavior through launchd and ec2-macos-init using the shown SetupStartup configuration and startup.sh.x command. Inspect when the module runs relative to user login and how RunAsUser is handled. Done means the configured binary runs reliably during boot, without requiring a user to log in.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, macos
- Domain
- infrastructure, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100