-
-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[mirotalkbro] - add workflows build, update dockerfile and dep
- Loading branch information
1 parent
cc8b09b
commit f10fed8
Showing
5 changed files
with
54 additions
and
12 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,34 @@ | ||
name: build | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v2 | ||
|
||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
|
||
- name: Login Docker Hub | ||
uses: docker/login-action@v2 | ||
with: | ||
username: ${{ secrets.DOCKERHUB_USERNAME }} | ||
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }} | ||
|
||
- name: Build and publish | ||
uses: docker/build-push-action@v3 | ||
with: | ||
context: ./ | ||
file: ./Dockerfile | ||
platforms: linux/amd64,linux/arm64 | ||
push: true | ||
tags: mirotalk/bro:latest |
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 @@ | ||
.github |
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 |
---|---|---|
@@ -1,17 +1,24 @@ | ||
FROM node:18-alpine | ||
# Use a lightweight Node.js image | ||
FROM node:20-alpine | ||
|
||
# Set working directory | ||
WORKDIR /src | ||
|
||
# Copy package.json and .env dependencies | ||
COPY package.json . | ||
COPY .env.template ./.env | ||
|
||
RUN \ | ||
npm install && \ | ||
npm cache clean --force && \ | ||
rm -rf /tmp/* /var/lib/apt/lists/* /var/tmp/* /usr/share/doc/* | ||
# Install necessary system packages and dependencies | ||
RUN apk add --no-cache \ | ||
bash \ | ||
vim \ | ||
&& npm install \ | ||
&& npm cache clean --force \ | ||
&& rm -rf /tmp/* /var/tmp/* /usr/share/doc/* | ||
|
||
# Copy the application code | ||
COPY app app | ||
COPY public public | ||
|
||
EXPOSE 3016:3016 | ||
|
||
CMD npm start | ||
# Set default command to start the application | ||
CMD ["npm", "start"] |
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 |
---|---|---|
|
@@ -8,7 +8,7 @@ | |
* @license For open source under AGPL-3.0 | ||
* @license For private project or commercial purposes contact us at: [email protected] | ||
* @author Miroslav Pejic - [email protected] | ||
* @version 1.0.49 | ||
* @version 1.0.50 | ||
*/ | ||
|
||
require('dotenv').config(); | ||
|
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