Update Rust crate log to v0.4.24 #3030
Workflow file for this run
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
name: Build & Check | |
on: | |
pull_request: | |
types: | |
- labeled | |
- edited | |
- synchronize | |
- unlabeled | |
branches: | |
- main | |
env: | |
CARGO_TERM_COLOR: always | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
lint: | |
name: Linting | |
runs-on: ubuntu-latest | |
continue-on-error: true | |
steps: | |
- uses: actions/setup-node@v4 | |
- uses: actions/checkout@v4 | |
- run: npx -y prettier --check ./ | |
# Uncomment the line below to include shell script linting | |
# - run: npx -y shellcheck ./.github/scripts/*.sh ./src/scripts/*.sh | |
step_summary_meta: | |
runs-on: ubuntu-latest | |
steps: | |
- run: | | |
PUSH=${{ contains(github.event.pull_request.labels.*.name, 'canary') }} | |
if [ "${PUSH}" = "true" ]; then | |
echo "## Image Published!" >> $GITHUB_STEP_SUMMARY | |
echo "> These are development images, expect bugs!!" | |
fi | |
build_rust: | |
name: Build Rust | |
uses: mbround18/gh-reusable/.github/workflows/rust-build-n-test.yml@main | |
build_docker: | |
name: "Build Docker" | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: true | |
max-parallel: 1 | |
matrix: | |
image: [odin, valheim] | |
include: | |
- image: odin | |
push: true | |
- image: valheim | |
push: ${{ contains(github.event.pull_request.labels.*.name, 'canary') }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Login to DockerHub | |
uses: docker/login-action@v3 | |
with: | |
username: mbround18 | |
password: ${{ secrets.DOCKER_TOKEN }} | |
- name: Docker meta | |
id: meta | |
uses: crazy-max/ghaction-docker-meta@v5 | |
with: | |
images: | | |
mbround18/${{ matrix.image }} | |
tags: | | |
type=sha | |
- name: Build ${{ matrix.image }} | |
id: docker_build | |
uses: docker/build-push-action@v6 | |
with: | |
file: ./Dockerfile.${{ matrix.image }} | |
push: ${{ matrix.push }} | |
tags: ${{ steps.meta.outputs.tags }} | |
labels: ${{ steps.meta.outputs.labels }} | |
cache-from: type=registry,ref=mbround18/${{ matrix.image }}:buildcache | |
cache-to: type=registry,ref=mbround18/${{ matrix.image }}:buildcache,mode=max | |
build-args: | | |
"GITHUB_SHA=${GITHUB_SHA}" | |
"GITHUB_REF=${GITHUB_REF}" | |
"GITHUB_REPOSITORY=${GITHUB_REPOSITORY}" | |
"ODIN_IMAGE_VERSION=${{ fromJSON(steps.meta.outputs.json).labels['org.opencontainers.image.version'] }}" | |
- name: Publish Image Summary | |
if: matrix.push | |
run: | | |
{ | |
echo "\`\`\`"; | |
if [ "${{ matrix.image }}" = "odin" ]; then | |
echo "docker run ${{ steps.meta.outputs.tags }}"; | |
else | |
echo "docker run --rm -it \\"; | |
echo " -e PASSWORD=\"123abc\" \\"; | |
echo " -e PUBLIC=\"1\" \\"; | |
echo " ${{ steps.meta.outputs.tags }}"; | |
fi; | |
echo "\`\`\`"; | |
} >> $GITHUB_STEP_SUMMARY |