Skip to content

Commit bc89aea

Browse files
committed
Fix manual devcontainer workflow on Linux
This ensures that devcontainer can be built and manually run based on the README.md instructions Signed-off-by: eriknordmark <[email protected]>
1 parent 272fc06 commit bc89aea

File tree

4 files changed

+3109
-3101
lines changed

4 files changed

+3109
-3101
lines changed

.devcontainer/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# syntax=docker/dockerfile:1.6.0
22
FROM alpine:3.18
33

4-
ARG TARGETOS
4+
ARG TARGETOS=linux
55
ARG TARGETARCH
66
ARG PROTOC_GEN_GO_VERSION=1.31.0
77
ARG PROTOC_VERSION=23.4
@@ -17,7 +17,7 @@ RUN arch=$(uname -m); \
1717
unzip protobuf.zip -d /usr/local; \
1818
rm -f protobuf.zip
1919

20-
ADD https://github.com/seamia/protodot.git /protodot
20+
RUN git clone https://github.com/seamia/protodot.git /protodot
2121
RUN go build -C /protodot -o /usr/local/bin/protodot .
2222

2323
RUN mkdir -p $(go env GOPATH)

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,14 @@ devcontainer --workspace-folder . up
103103
devcontainer exec --workspace-folder . make proto
104104
```
105105

106+
#### Manual ad-hoc use of devcontainer on Linux
107+
108+
First the devcontainer needs to be built and then run to do the make proto:
109+
```bash
110+
docker build -f .devcontainer/Dockerfile -t eve-api-builder .
111+
docker run --rm -v $(pwd):/src -w /src -u $(id -u) eve-api-builder make proto
112+
```
113+
106114
#### Local
107115

108116
If running locally, you need to install the prerequisites yourself.

images/devconfig.png

252 KB
Loading

0 commit comments

Comments
 (0)