-
Notifications
You must be signed in to change notification settings - Fork 93
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
Move Dev Environment to MacOS #4879
Move Dev Environment to MacOS #4879
Conversation
eb9e7f1
to
7dafbb3
Compare
7dafbb3
to
712681e
Compare
@$(if ${DD_API_KEY}, $(call sendMetrics)) | ||
@rm start-time | ||
OS ?= linux | ||
ARCH ?= $(shell go env GOARCH) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the go build commands do not respect these vars. is that intended?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes because the kots cli will typically run on your mac, not inside the container. the one inside the container gets built differently.
COPY cmd ./cmd | ||
COPY pkg ./pkg | ||
COPY web/webcontent.go ./web/webcontent.go | ||
RUN go install github.com/go-delve/delve/cmd/[email protected] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RUN go install github.com/go-delve/delve/cmd/dlv@v1.22.1 | |
RUN go install github.com/go-delve/delve/cmd/dlv@v1.23.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i think there was a compatibility issue that one of the CRE engineers had to deal with when using the latest version, so i didn't wanna upgrade it.
- name: dlv | ||
containerPort: 30001 | ||
resources: | ||
limits: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
any reason to limit this in dev?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, to mimic prod as there were times where that bit us. i guess we remove the limits on "up" so that might be sufficient?
@@ -0,0 +1,31 @@ | |||
#!/bin/bash | |||
|
|||
set -e |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Its always best to start with -euo pipefail
to prevent bugs down the line
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i had it like that, but it was failing for me for some reason. i can try it again
What this PR does / why we need it:
Changes the dev environment to run locally on MacOS instead of Github Codespaces.
Benefits:
Which issue(s) this PR fixes:
SC-111503
Does this PR require a test?
NONE
Does this PR require a release note?
Does this PR require documentation?
NONE
Demo
https://www.loom.com/share/79da18e8cd5147efa2dc1811664b437a?sid=7600731b-3deb-40cc-ab7c-932380dd5184