-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from Dahlgren/fix/linter-yaml-warnings
Fix YAML warnings in linters
- Loading branch information
Showing
4 changed files
with
69 additions
and
55 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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
--- | ||
ignored: | ||
- DL3008 # Pinned apt versions |
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,66 +1,74 @@ | ||
--- | ||
name: Publish Docker | ||
|
||
on: [push] | ||
on: | ||
push: | ||
|
||
env: | ||
IMAGE_TAG: ghcr.io/${{ github.repository_owner }}/arma-reforger:edge | ||
|
||
jobs: | ||
build: | ||
name: Build Image | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Build Image | ||
run: docker build . -t arma-reforger | ||
- name: Save Image | ||
run: docker save arma-reforger | gzip > image.tar.gz | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: image | ||
path: image.tar.gz | ||
if-no-files-found: error | ||
retention-days: 7 | ||
- uses: actions/checkout@master | ||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- name: Build Image | ||
run: docker build . -t arma-reforger | ||
- name: Save Image | ||
run: docker save arma-reforger | gzip > image.tar.gz | ||
- uses: actions/upload-artifact@v2 | ||
with: | ||
name: image | ||
path: image.tar.gz | ||
if-no-files-found: error | ||
retention-days: 7 | ||
|
||
test: | ||
name: Test Image | ||
runs-on: ubuntu-latest | ||
needs: [ build ] | ||
needs: | ||
- build | ||
steps: | ||
- uses: actions/checkout@master | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: image | ||
- name: Load Image | ||
run: docker load < image.tar.gz | ||
- name: Run Image | ||
run: docker run -d -p 17777:17777/udp arma-reforger | ||
- name: Install python dependencies | ||
run: python3 -m pip install python-a2s | ||
- name: Run Test | ||
run: python3 ./.github/scripts/steam-query.py | ||
- uses: actions/checkout@master | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: image | ||
- name: Load Image | ||
run: docker load < image.tar.gz | ||
- name: Run Image | ||
run: docker run -d -p 17777:17777/udp arma-reforger | ||
- name: Install python dependencies | ||
run: python3 -m pip install python-a2s | ||
- name: Run Test | ||
run: python3 ./.github/scripts/steam-query.py | ||
|
||
main_publish: | ||
name: Publish Image | ||
runs-on: ubuntu-latest | ||
needs: [ build, test ] | ||
needs: | ||
- build | ||
- test | ||
if: github.ref == 'refs/heads/main' | ||
steps: | ||
- name: Login to GHCR | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: image | ||
- name: Load Image | ||
run: docker load < image.tar.gz | ||
- name: Tag Image | ||
run: docker tag arma-reforger ghcr.io/${{ github.repository_owner }}/arma-reforger:edge | ||
- name: Push Image | ||
run: docker push ghcr.io/${{ github.repository_owner }}/arma-reforger:edge | ||
- name: Login to GHCR | ||
uses: docker/login-action@v1 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
- uses: actions/download-artifact@v2 | ||
with: | ||
name: image | ||
- name: Load Image | ||
run: docker load < image.tar.gz | ||
- name: Tag Image | ||
run: docker tag arma-reforger "$IMAGE_TAG" | ||
- name: Push Image | ||
run: docker push "$IMAGE_TAG" |
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,15 +1,19 @@ | ||
--- | ||
name: Lint | ||
|
||
on: [push, pull_request] | ||
on: | ||
push: | ||
pull_request: | ||
|
||
jobs: | ||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Lint | ||
uses: github/super-linter@v4 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Lint | ||
uses: github/super-linter@v4 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
YAML_ERROR_ON_WARNING: true |
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,3 +1,4 @@ | ||
--- | ||
version: '3.8' | ||
services: | ||
arma-reforger: | ||
|