forked from konveyor/analyzer-lsp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
✨ add dockerfiles for providers, run demo using external providers
- Loading branch information
1 parent
1e8c3cf
commit 6e10dd6
Showing
6 changed files
with
183 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
FROM golang:1.20 as go-builder | ||
|
||
WORKDIR /generic-external-provider | ||
|
||
COPY go.mod go.mod | ||
COPY go.sum go.sum | ||
RUN go mod download | ||
|
||
COPY main.go main.go | ||
COPY pkg/ pkg/ | ||
RUN go build -o generic-external-provider main.go | ||
|
||
FROM quay.io/konveyor/golang-dependency-provider as go-dep-provider | ||
|
||
FROM registry.access.redhat.com/ubi9/ubi-minimal:latest | ||
|
||
ENV NODEJS_VERSION=18 | ||
RUN echo -e "[nodejs]\nname=nodejs\nstream=${NODEJS_VERSION}\nprofiles=\nstate=enabled\n" > /etc/dnf/modules.d/nodejs.module | ||
RUN microdnf install gcc-c++ python-devel go-toolset python3-devel nodejs -y && \ | ||
microdnf clean all && \ | ||
rm -rf /var/cache/dnf | ||
RUN python3 -m ensurepip --upgrade | ||
RUN python3 -m pip install 'python-lsp-server>=1.8.2' | ||
RUN npm install -g typescript-language-server typescript | ||
RUN go install golang.org/x/tools/gopls@latest | ||
|
||
COPY --from=go-builder /generic-external-provider/generic-external-provider /usr/local/bin/generic-external-provider | ||
COPY --from=go-dep-provider /usr/local/bin/go-dependency-provider /usr/local/bin/go-dependency-provider | ||
|
||
ENTRYPOINT [ "/usr/local/bin/generic-external-provider" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
FROM golang:1.20 as go-builder | ||
|
||
WORKDIR /go-dependency-provider | ||
|
||
COPY go.mod go.mod | ||
COPY go.sum go.sum | ||
RUN go mod download | ||
|
||
COPY main.go main.go | ||
RUN go build -o go-dependency-provider main.go | ||
|
||
FROM registry.access.redhat.com/ubi9/ubi-minimal:latest | ||
|
||
COPY --from=go-builder /go-dependency-provider/go-dependency-provider /usr/local/bin/go-dependency-provider | ||
|
||
ENTRYPOINT [ "/usr/local/bin/go-dependency-provider" ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
FROM golang:1.20 as go-builder | ||
|
||
WORKDIR /yq-external-provider | ||
|
||
COPY go.mod go.mod | ||
COPY go.sum go.sum | ||
RUN go mod download | ||
|
||
COPY main.go main.go | ||
COPY pkg/ pkg/ | ||
|
||
RUN go build -o yq-external-provider main.go | ||
|
||
FROM registry.access.redhat.com/ubi9/ubi-minimal:latest | ||
|
||
RUN microdnf install -y wget tar xz gzip && \ | ||
microdnf clean all | ||
ARG TARGETARCH | ||
ARG YQ_VERSION="v4.40.5" | ||
ARG YQ_BINARY="yq_linux_${TARGETARCH}" | ||
RUN wget "https://github.com/mikefarah/yq/releases/download/${YQ_VERSION}/${YQ_BINARY}.tar.gz" -O - | tar xz && \ | ||
mv ${YQ_BINARY} /usr/local/bin/yq | ||
|
||
COPY --from=go-builder /yq-external-provider/yq-external-provider /usr/local/bin/yq-external-provider | ||
|
||
ENTRYPOINT [ "/usr/local/bin/yq-external-provider" ] |