Skip to content

Commit

Permalink
feat: use wails to build in the Docker pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
fdidron committed Sep 1, 2021
1 parent ec39df5 commit 096957b
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 27,987 deletions.
17 changes: 7 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,20 @@ RUN dnf install -y dnf-plugins-core && \
dnf config-manager --set-enabled powertools && \
dnf install -y \
gcc gtk3 gtk3-devel \
libusb libusb-devel \
libusb-devel \
nodejs npm pkg-config \
webkit2gtk3 webkit2gtk3-devel wget && \
webkit2gtk3-devel wget && \
mkdir project && \
wget https://golang.org/dl/go1.16.6.linux-amd64.tar.gz -O go.tar.gz

RUN tar -zxf go.tar.gz && \
cp -r ./go /usr/local/bin

ENV PATH=$PATH:/usr/local/bin/go/bin
ENV GOPATH=/usr/local/bin/go

RUN npm i -g yarn
RUN go get -u github.com/wailsapp/wails/cmd/wails

WORKDIR project
COPY /*.go ./
Expand All @@ -23,12 +27,5 @@ COPY /frontend ./frontend
COPY /project.json ./project.json
COPY /wally ./wally

WORKDIR frontend

RUN npm install && \
npm run build

WORKDIR ..

RUN go build -o wally-bin
RUN wails build
ENTRYPOINT ["sleep", "infinity"]
2 changes: 1 addition & 1 deletion build.linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ CONTAINER_NAME="$(uuidgen)"
docker build -t wally .
docker run --rm -d --name "$CONTAINER_NAME" wally

docker cp $CONTAINER_NAME:/project/wally-bin ./dist/linux64/wally
docker cp $CONTAINER_NAME:/project/build/wally ./dist/linux64/wally

docker kill --signal SIGKILL "$CONTAINER_NAME"
Loading

0 comments on commit 096957b

Please sign in to comment.