Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix mobile CI + Some small CI improvements #2113

Merged
merged 1 commit into from
Feb 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/setup-system/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ runs:
if: ${{ runner.os != 'Linux' }}
uses: ilammy/setup-nasm@v1

- name: Install Mold
- name: Install Mold (linker)
shell: bash
if: ${{ runner.os == 'Linux' }}
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/cache-factory.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -64,16 +64,16 @@ jobs:
remove-haskell: 'true'
remove-docker-images: 'true'

- name: Checkout repository
uses: actions/checkout@v4

- name: Symlink target to C:\
if: ${{ runner.os == 'Windows' }}
shell: powershell
run: |
New-Item -ItemType Directory -Force -Path C:\spacedrive_target
New-Item -Path target -ItemType Junction -Value C:\spacedrive_target

- name: Checkout repository
uses: actions/checkout@v4

- name: Setup System and Rust
uses: ./.github/actions/setup-system
with:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ on:

env:
SPACEDRIVE_CUSTOM_APT_FLAGS: --no-install-recommends
# From: https://github.com/rust-lang/rust-analyzer/blob/master/.github/workflows/ci.yaml
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
RUST_BACKTRACE: short
RUSTUP_MAX_RETRIES: 10

# Cancel previous runs of the same workflow on the same branch.
concurrency:
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/mobile-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ on:
env:
SPACEDRIVE_CUSTOM_APT_FLAGS: --no-install-recommends
SPACEDRIVE_CI: '1'
# From: https://github.com/rust-lang/rust-analyzer/blob/master/.github/workflows/ci.yaml
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
RUST_BACKTRACE: short
RUSTUP_MAX_RETRIES: 10

# Cancel previous runs of the same workflow on the same branch.
concurrency:
Expand Down Expand Up @@ -199,7 +204,7 @@ jobs:
- name: Run Simulator
uses: futureware-tech/simulator-action@v2
with:
model: 'iPhone 11'
model: 'iPhone SE (3rd generation)'

- name: Run Tests
run: |
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ on:
workflow_dispatch:
# NOTE: For Linux builds, we can only build with Ubuntu. It should be the oldest base system we intend to support. See PR-759 & https://tauri.app/v1/guides/building/linux for reference.

# From: https://github.com/rust-lang/rust-analyzer/blob/master/.github/workflows/release.yaml#L13-L21
env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
RUSTUP_MAX_RETRIES: 10

jobs:
desktop-main:
strategy:
Expand Down
11 changes: 10 additions & 1 deletion apps/server/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ RUN --mount=type=cache,target=/var/cache/apt --mount=type=cache,target=/var/lib/
FROM base as build-base

RUN --mount=type=cache,target=/var/cache/apt --mount=type=cache,target=/var/lib/apt \
apt-get install build-essential git sudo unzip wget
apt-get install build-essential git sudo unzip wget curl

RUN wget -qO- https://get.pnpm.io/install.sh | env SHELL=bash PNPM_HOME=/usr/share/pnpm sh -

Expand Down Expand Up @@ -60,6 +60,15 @@ RUN wget -qO- https://sh.rustup.rs | sh -s -- -yq --profile minimal

ENV PATH="/root/.cargo/bin:$PATH"

# From: https://github.com/rust-lang/rust-analyzer/blob/master/.github/workflows/release.yaml#L13-L21
ENV CARGO_NET_RETRY=10
ENV CARGO_INCREMENTAL=0
ENV RUSTUP_MAX_RETRIES=10

# Install mold (linker)
RUN curl -L# 'https://github.com/rui314/mold/releases/download/v2.4.0/mold-2.4.0-x86_64-linux.tar.gz' \
| sudo tar -xzf- -C /usr/local

RUN --mount=type=cache,target=/var/cache/apt --mount=type=cache,target=/var/lib/apt \
env CI=true ./scripts/setup.sh

Expand Down
Loading