-
Notifications
You must be signed in to change notification settings - Fork 184
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #811 from maticnetwork/vcastellm/pos-296-bump-go-v…
…ersion-in-bor-and-heimdall Bump Go version to v1.18.1
- Loading branch information
Showing
4 changed files
with
71 additions
and
3 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: Docker Image CI | ||
|
||
on: | ||
push: | ||
tags: | ||
- 'v*.*.*' | ||
# to be used by fork patch-releases ^^ | ||
- 'v*.*.*-*' | ||
|
||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Build the Docker image | ||
env: | ||
DOCKERHUB: ${{ secrets.DOCKERHUB }} | ||
DOCKERHUB_KEY: ${{ secrets.DOCKERHUB_KEY }} | ||
run: | | ||
ls -l | ||
echo "Docker login" | ||
docker login -u $DOCKERHUB -p $DOCKERHUB_KEY | ||
echo "running build" | ||
docker build -f Dockerfile.deprecated -t maticnetwork/heimdall:${GITHUB_REF/refs\/tags\//} . | ||
echo "pushing image" | ||
docker push maticnetwork/heimdall:${GITHUB_REF/refs\/tags\//} | ||
echo "DONE!" |
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,31 @@ | ||
# Simple usage with a mounted data directory: | ||
# > docker build -t maticnetwork/heimdall:<tag> . | ||
# > docker run -it -p 26657:26657 -p 26656:26656 -v ~/.heimdalld:/root/.heimdalld maticnetwork/heimdall:<tag> heimdalld init | ||
|
||
# Start from a Debian image with the latest version of Go installed | ||
# and a workspace (GOPATH) configured at /go. | ||
FROM golang:latest | ||
|
||
# update available packages | ||
RUN apt-get update -y && apt-get upgrade -y && apt install build-essential -y | ||
|
||
# create go src directory and clone heimdall | ||
RUN mkdir -p /root/heimdall | ||
|
||
# add code to docker instance | ||
ADD . /root/heimdall/ | ||
|
||
# change work directory | ||
WORKDIR /root/heimdall | ||
|
||
# GOBIN required for go install | ||
ENV GOBIN $GOPATH/bin | ||
|
||
# run build | ||
RUN make install | ||
|
||
# add volumes | ||
VOLUME [ "/root/.heimdalld", "./logs" ] | ||
|
||
# expose ports | ||
EXPOSE 1317 26656 26657 |
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,10 @@ | ||
#!/usr/bin/env sh | ||
|
||
# start processes | ||
heimdalld start > ./logs/heimdalld.log & | ||
heimdalld rest-server > ./logs/heimdalld-rest-server.log & | ||
sleep 100 | ||
bridge start --all > ./logs/bridge.log & | ||
|
||
# tail logs | ||
tail -f ./logs/heimdalld.log ./logs/heimdalld-rest-server.log ./logs/bridge.log |