Skip to content

Dockerized MSF RPC Daemon #43680

Dockerized MSF RPC Daemon

Dockerized MSF RPC Daemon #43680

Workflow file for this run

name: Dockerized MSF RPC Daemon
permissions:
contents: write
on:
workflow_dispatch:
schedule:
- cron: '* * * * */1'
#[workflow_call]
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
name: build package
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
path: "repo"
- name: Bump version and push tag
id: tag_version
uses: mathieudutour/github-tag-action@v6.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
#- name: Release
# uses: softprops/action-gh-release@v1
# with:
# tag_name: ${{ steps.tag_version.outputs.new_tag }}
# fail_on_unmatched_files: true
# generate_release_notes: true
# files: |
# repo/dist/*
# TODO new image
- name: Authenticate with Docker Hub
run: |
docker login -u $DOCKERHUB_USERNAME -p $DOCKERHUB_PASSWORD
env:
DOCKERHUB_USERNAME: ${{ secrets.DOCKERHUB_USERNAME }}
DOCKERHUB_PASSWORD: ${{ secrets.DOCKERHUB_PASSWORD }}
- name: Build Docker Image
working-directory: "repo"
run: |
docker build -t "innovanon/msfrpcd:$TEAMHACK_VERSION" .
env:
TEAMHACK_VERSION: ${{ steps.tag_version.outputs.new_tag }}
- name: Tag Docker Image
run: |
docker tag "innovanon/msfrpcd:$TEAMHACK_VERSION" \
innovanon/msfrpcd:latest
env:
TEAMHACK_VERSION: ${{ steps.tag_version.outputs.new_tag }}
- name: Deploy Docker Image
run: |
docker push innovanon/msfrpcd
# TODO new image
- name: Configure GPG Key
run: |
echo -n "$GPG_SIGNING_KEY" | gpg --import
#echo -n "$GPG_SIGNING_KEY" | base64 --decode | gpg --import
env:
GPG_SIGNING_KEY: ${{ secrets.GPG_SIGNING_KEY }}
- name: Sign Installation Package
working-directory: "repo"
run: |
gpg --yes --detach-sig Dockerfile
gpg --yes --detach-sig docker-compose.yaml
- name: Release
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ steps.tag_version.outputs.new_tag }}
fail_on_unmatched_files: true
generate_release_notes: true
files: |
repo/*