Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add http env to workers execution #184

Merged
merged 1 commit into from
Nov 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions HACKING.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ export CONSUMER_ID=$(openssl x509 -in cert.pem -subject -nocert | cut -f3 -d" ")
mosquitto_pub --host 127.0.0.1 --port 1883 --topic "yggdrasil/${CONSUMER_ID}/control/in" --message "{\"type\":\"command\",\"message_id\":\"$(uuidgen | tr -d '\n')\",\"version\":1,\"sent\":\"$(date --iso-8601=seconds --utc | tr -d '\n')\",\"content\":{\"command\":\"ping\"}}"
```

Send a data message to `echo worker`
```
mosquitto_pub --host 127.0.0.1 --port 1883 --topic yggdrasil/${CONSUMER_ID}/data/in --message "{\"type\":\"data\",\"message_id\":\"$(uuidgen | tr -d '\n')\", \"response_to\":\" \",\"version\":1,\"sent\":\"$(date --iso-8601=seconds --utc | tr -d '\n')\",\"directive\":\"echo\",\"metadata\":\"{}\",\"content\":{\"hello world\"}}"
```


# Call Graphs

Call graphs can be generated to provide a high-level overview of the
Expand Down
5 changes: 5 additions & 0 deletions cmd/yggd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,11 @@ func main() {
env := []string{
"YGG_SOCKET_ADDR=unix:" + c.String("socket-addr"),
"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin",
subpop marked this conversation as resolved.
Show resolved Hide resolved
"http_proxy=" + os.Getenv("http_proxy"),
"https_proxy=" + os.Getenv("https_proxy"),
"HTTPS_PROXY=" + os.Getenv("HTTPS_PROXY"),
"no_proxy=" + os.Getenv("no_proxy"),
"NO_PROXY=" + os.Getenv("NO_PROXY"),
}
for _, info := range fileInfos {
if strings.HasSuffix(info.Name(), "worker") {
Expand Down
Loading