Skip to content

Commit

Permalink
Add gitpod file
Browse files Browse the repository at this point in the history
  • Loading branch information
Vincent056 committed May 31, 2024
1 parent 893ea06 commit df8cfa7
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
14 changes: 14 additions & 0 deletions .gitpod.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
FROM gitpod/workspace-full

# Install go
RUN rm -rf $HOME/go $HOME/go-packages

RUN echo "export GOPATH=/workspace/go" >> ~/.bashrc.d/300-go && \
echo "export GOBIN=\$GOPATH/bin" >> ~/.bashrc.d/300-go && \
echo "export GOROOT=${HOME}/go" >> ~/.bashrc.d/300-go && \
echo "export PATH=\$GOROOT/bin:\$GOBIN:\$PATH" >> ~/.bashrc
RUN bash -c "source ~/.bashrc && source ~/.bashrc.d/300-go"

RUN export CUSTOM_GO_VERSION=$(curl -sSL "https://raw.githubusercontent.com/ComplianceAsCode/compliance-operator/master/go.mod" | awk '/^go/{print $2".0"}') && \
curl -fsSL "https://dl.google.com/go/go${CUSTOM_GO_VERSION}.linux-amd64.tar.gz" | \
tar -xz -C $HOME
10 changes: 10 additions & 0 deletions .gitpod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
image:
file: .gitpod.Dockerfile

vscode:
extensions:
- golang.go
- premparihar.gotestexplorer
- eamodio.gitlens # cool git extension with a bunch of extra features


0 comments on commit df8cfa7

Please sign in to comment.