Skip to content
This repository has been archived by the owner on Apr 27, 2024. It is now read-only.

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
tarampampam committed May 24, 2023
1 parent ea613df commit 54fe59f
Show file tree
Hide file tree
Showing 8 changed files with 205 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# EditorConfig docs: <https://editorconfig.org/>

root = true

[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
indent_size = 2
trim_trailing_whitespace = true
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# Docs: <https://docs.github.com/en/free-pro-team@latest/github/administering-a-repository/customizing-dependency-updates>

version: 2

updates:
- package-ecosystem: github-actions
directory: /
schedule: {interval: monthly}
33 changes: 33 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: release

on:
release: # Docs: <https://help.github.com/en/articles/events-that-trigger-workflows#release-event-release>
types: [published]

jobs:
update-git-tag: # Reason: <https://github.com/actions/toolkit/blob/master/docs/action-versioning.md#recommendations>
name: Update latest major git tag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- {uses: gacts/github-slug@v1, id: slug}

- name: Setup git
env: {REPO_PATH: "${{ github.repository_owner }}/${{ github.event.repository.name }}"}
run: |
git config --local user.email '[email protected]'
git config --local user.name "${{ github.actor }}"
git remote set-url origin "https://${{ github.actor }}:${{ secrets.GITHUB_TOKEN }}@github.com/$REPO_PATH.git"
- name: Update major tag
env: {VERSION: "${{ steps.slug.outputs.version-major }}"}
run: |
git tag -fa "v$VERSION" -m "Update v$VERSION tag (using GitHub actions)"
git push --set-upstream origin "v$VERSION" --force
- name: Update minor tag
env: {VERSION: "${{ steps.slug.outputs.version-major }}.${{ steps.slug.outputs.version-minor }}"}
run: |
git tag -fa "v$VERSION" -m "Update v$VERSION tag (using GitHub actions)"
git push --set-upstream origin "v$VERSION" --force
33 changes: 33 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: tests

on:
push:
branches: [master, main]
tags-ignore: ['**']
paths-ignore: ['**.md']
pull_request:
paths-ignore: ['**.md']

jobs:
gitleaks:
name: Gitleaks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with: {fetch-depth: 0}

- name: Check for GitLeaks
uses: gacts/gitleaks@v1 # Action page: <https://github.com/gacts/gitleaks>

run-this-action:
name: Run action (${{ matrix.runs-on }})
runs-on: ${{ matrix.runs-on }}
strategy:
fail-fast: false
matrix:
runs-on: [ubuntu-latest] # macos-latest, windows-latest
steps:
- uses: actions/checkout@v3

- name: Run this action
uses: ./
8 changes: 8 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# IDEs
/.vscode
/.idea

# Temp dirs & trash
/temp
/tmp
.DS_Store
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2021 https://github.com/gacts

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
53 changes: 52 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,52 @@
# install-podman
<p align="center">
<img src="https://github.com/gacts/install-podman/assets/7326800/d427cdc0-a49d-4153-8a75-e8c9827f0574" alt="Logo" width="140" />
</p>

# Install Podman

![Release version][badge_release_version]
[![Build Status][badge_build]][link_build]
[![License][badge_license]][link_license]

Composite GitHub Action installs a fresh Podman version in your GitHub Actions workflow.

## Usage

```yaml
jobs:
install-podman:
runs-on: ubuntu-latest
steps:
- uses: gacts/install-podman@v1
#with:
# kind: unstable # `testing` by default

- run: dnscontrol version # any dnscontrol command can be executed
```

> Tip: Use [Dependabot][use_dependabot] to maintain your `gacts/install-podman` version updated in your GitHub workflows.
## Support

[![Issues][badge_issues]][link_issues]
[![Issues][badge_pulls]][link_pulls]

If you find any action errors - please, [make an issue][link_create_issue] in the current repository.

## License

This is open-sourced software licensed under the [MIT License][link_license].

[badge_build]:https://img.shields.io/github/actions/workflow/status/gacts/install-podman/test.yml?branch=master&maxAge=30
[badge_release_version]:https://img.shields.io/github/release/gacts/install-podman.svg?maxAge=30
[badge_license]:https://img.shields.io/github/license/gacts/install-podman.svg?longCache=true
[badge_issues]:https://img.shields.io/github/issues/gacts/install-podman.svg?maxAge=45
[badge_pulls]:https://img.shields.io/github/issues-pr/gacts/install-podman.svg?maxAge=45

[link_build]:https://github.com/gacts/install-podman/actions
[link_license]:https://github.com/gacts/install-podman/blob/master/LICENSE
[link_issues]:https://github.com/gacts/install-podman/issues
[link_create_issue]:https://github.com/gacts/install-podman/issues/new
[link_pulls]:https://github.com/gacts/install-podman/pulls

[use_dependabot]:https://docs.github.com/en/code-security/supply-chain-security/keeping-your-dependencies-updated-automatically/keeping-your-actions-up-to-date-with-dependabot
39 changes: 39 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Metadata syntax: <https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-github-actions>

name: Install Podman
description: Installs a fresh Podman version in your GitHub Actions workflow

inputs:
kind:
description: The version kind
default: 'testing'

runs:
using: composite
steps: # manual: <https://podman.io/docs/installation#debian>
- name: Install GPG key
if: ${{ inputs.cache-key-suffix == 'testing' }}
shell: bash
run: |
curl -fsSL https://download.opensuse.org/repositories/devel:kubic:libcontainers:unstable/Debian_Testing/Release.key \
| gpg --dearmor \
| sudo tee /etc/apt/keyrings/devel_kubic_libcontainers_unstable.gpg > /dev/null
- name: Install repository
if: ${{ inputs.cache-key-suffix == 'testing' }}
shell: bash
run: |
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/devel_kubic_libcontainers_unstable.gpg] \
https://download.opensuse.org/repositories/devel:kubic:libcontainers:unstable/Debian_Testing/ /" \
| sudo tee /etc/apt/sources.list.d/devel:kubic:libcontainers:unstable.list > /dev/null
- name: Install Podman
if: ${{ inputs.cache-key-suffix == 'testing' }}
shell: bash
run: |
sudo apt-get -q update
sudo apt-get -yq install podman
branding:
icon: download
color: purple

0 comments on commit 54fe59f

Please sign in to comment.