https://github.com/zanzythebar/tauridocker
https://github.com/zanzythebar/tauridocker
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/zanzythebar/tauridocker
- Owner: ZanzyTHEbar
- Created: 2023-05-10T12:13:45.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-06-01T13:08:01.000Z (over 2 years ago)
- Last Synced: 2025-04-06T11:50:00.395Z (7 months ago)
- Language: Dockerfile
- Size: 21.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# Tauri in a Docker container
This is a custom Docker image for [Tauri](https://tauri.app/).
## Usage
### Github Actions
```yaml
- name: Run Docker container
uses: addnab/docker-run-action@v3
with:
image: ghcr.io/zanzythebar/tauridocker:latest
options: -v ${{ github.workspace }}/some_dir:/workspace
run: |
export NODE_VERSION=16.13.0
mkdir build
echo "::group::install node dependencies"
npm install -g pnpm
npm install -g typescript
pnpm fetch
pnpm install
echo "::group::tauri build"
pnpm tauri build
echo "::endgroup::"
- name: Verify build
run: |
ls -la build
```
```yaml
- name: Checkout repository
uses: actions/checkout@v3
with:
token: ${{ env.GITHUB_TOKEN }}
- name: Build the App (Linux)
if: matrix.platform == 'ubuntu-latest'
uses: addnab/docker-run-action@v3
with:
image: ghcr.io/zanzythebar/tauridocker:latest
options: -v ${{ github.workspace }}:/workspace
run: |
echo "::group::install node dependencies"
npm install -g pnpm
npm install -g typescript
pnpm fetch
pnpm install
echo "::group::tauri build"
pnpm tauri build
echo "::endgroup::"
- name: Archive the App (Linux)
if: matrix.platform == 'ubuntu-latest'
uses: actions/upload-artifact@v3
with:
name: production-files
path: |
src-tauri/target/release/bundle/deb/*.deb
src-tauri/target/release/bundle/appimage/*.AppImage
retention-days: 5
if-no-files-found: error
- name: Verify build (Linux)
if: matrix.platform == 'ubuntu-latest'
run: |
ls -la src-tauri/target/release/bundle/appimage
ls -la src-tauri/target/release/bundle/deb
```
### Docker
```bash
docker run --name tauridocker -v ~/app:/workspace ghcr.io/zanzythebar/tauridocker:latest
```
> **Note**: Volume mounting is currently in development and may not work as expected. Please make a `pr` if you find any issues.
Alternatively you could use a data volume container to save the some configurations. First create the data volume container. You can use other docker images for this, or mount directories from the system.
### Example
```bash
docker run --name vc_tauridocker zanzythebar/vc_tauridocker:latest
```
Then add the following line to the docker run call:
```bash
--volumes-from=vc_tauridocker \
```