Compare commits
4 commits
dea08e07df
...
10e2740053
Author | SHA1 | Date | |
---|---|---|---|
10e2740053 | |||
3cde8dde52 | |||
43b974361e | |||
95e21cb4fe |
6 changed files with 476 additions and 582 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,2 +1 @@
|
|||
.envrc
|
||||
**/target/
|
||||
|
|
|
@ -6,7 +6,7 @@ fava_envelope==0.5.9
|
|||
fava-investor==0.7.0
|
||||
# renovate: branch=main
|
||||
git+https://github.com/andreasgerstmayr/fava-dashboards.git@50a0b7c8b20e50b15bf491329e1ecab6598d8b96
|
||||
git+https://github.com/beancount/beangrow.git@8bc91509db0454ad87e257431c74d4d52e991bc9
|
||||
git+https://github.com/beancount/beangrow.git@56f1c2a62c808917fad66fbaa4aa4028a6d2def6
|
||||
# renovate: branch=main
|
||||
git+https://github.com/daniel-wells/beancount_checkclosed.git@5abc380703105c12b518144f83a5c4fe25cc8f39
|
||||
# renovate: branch=main
|
||||
|
|
962
images/gitea/Cargo.lock
generated
962
images/gitea/Cargo.lock
generated
File diff suppressed because it is too large
Load diff
|
@ -1,29 +1,40 @@
|
|||
FROM rust:1.80.1-alpine3.20 AS builder
|
||||
FROM rust:alpine AS builder
|
||||
|
||||
RUN apk add --no-cache musl-dev;
|
||||
# Use a dummy project to ensure the crate index is up to date.
|
||||
RUN set -e; \
|
||||
cargo new --color always /tmp/dummy; \
|
||||
cargo add --color always --manifest-path /tmp/dummy/Cargo.toml serde; \
|
||||
rm -rf /tmp/dummy; \
|
||||
cargo new --color always --bin /app
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
RUN apk add --no-cache \
|
||||
# openssl-dev \
|
||||
# pkgconfig \
|
||||
musl-dev
|
||||
|
||||
# Build dependencies with a dummy project to cache those regardless of changes
|
||||
# in the actual source code
|
||||
COPY ./Cargo.toml ./Cargo.lock /app/
|
||||
RUN cargo build --color always --release --locked
|
||||
|
||||
COPY . .
|
||||
RUN touch -a -m ./src/main.rs && cargo build --color always --release --locked
|
||||
|
||||
RUN --mount=type=cache,id=cargo-registry,target=/usr/local/cargo/registry \
|
||||
--mount=type=cache,id=cargo-target,target=/app/target \
|
||||
set -e; \
|
||||
cargo build --color always --release --locked; \
|
||||
# The cache will disappear after this directive, so we
|
||||
# need to copy the binary to a persistent place.
|
||||
cp target/release/gitea /app/gitea;
|
||||
FROM alpine AS final
|
||||
|
||||
FROM alpine:3.20.2 AS final
|
||||
|
||||
RUN apk add --no-cache ca-certificates;
|
||||
RUN apk add --no-cache ca-certificates
|
||||
|
||||
ENV RUST_BACKTRACE=1
|
||||
ENV RUST_LOG=info
|
||||
|
||||
COPY --from=builder /app/gitea /bin/
|
||||
COPY --from=builder /app/target/release/gitea /bin/
|
||||
|
||||
# Put this last, as it's the only thing that's different between variants.
|
||||
# This way, the previous layers can all be shared.
|
||||
|
||||
ARG VARIANT="missing build arg 'VARIANT'"
|
||||
ARG VERSION="0.1.0"
|
||||
LABEL version="$VERSION"
|
||||
COPY ./shims/${VARIANT}/* /opt/resource/
|
||||
|
|
|
@ -51,10 +51,6 @@
|
|||
{
|
||||
"type": "file",
|
||||
"name": "rust-xwin"
|
||||
},
|
||||
{
|
||||
"type": "file",
|
||||
"name": "gitea"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -1,52 +0,0 @@
|
|||
{% macro resource(variant, registry_url) -%}
|
||||
- name: image-gitea-{{ variant }}
|
||||
type: registry-image
|
||||
icon: docker
|
||||
source:
|
||||
repository: "{{ registry_url }}/gitea-{{ variant }}"
|
||||
tag: latest
|
||||
{% endmacro %}
|
||||
|
||||
{% macro build(variant) -%}
|
||||
- task: build-gitea-{{ variant }}
|
||||
file: repo/tasks/build-image.yml
|
||||
privileged: true
|
||||
vars:
|
||||
context: repo/images/gitea
|
||||
target: ''
|
||||
dockerfile: ''
|
||||
params:
|
||||
VARIANT: {{ variant }}
|
||||
output_mapping:
|
||||
image: image-gitea-{{ variant }}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro put(variant) -%}
|
||||
- put: image-gitea-{{ variant }}
|
||||
inputs: detect
|
||||
params: { image: image-gitea-{{ variant }}/image.tar }
|
||||
no_get: true
|
||||
{% endmacro %}
|
||||
|
||||
{% macro resources(registry_url) -%}
|
||||
{{ resource('package', registry_url) }}
|
||||
{{ resource('status', registry_url) }}
|
||||
{{ resource('pr', registry_url) }}
|
||||
{% endmacro %}
|
||||
|
||||
{% macro jobs() -%}
|
||||
- name: gitea
|
||||
serial: true
|
||||
plan:
|
||||
- get: repo
|
||||
trigger: true
|
||||
{{ build('package') }}
|
||||
{{ build('status') }}
|
||||
{{ build('pr') }}
|
||||
- in_parallel:
|
||||
steps:
|
||||
{{ put('package') }}
|
||||
{{ put('status') }}
|
||||
{{ put('pr') }}
|
||||
{% endmacro %}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue