mirror of
https://github.com/edgelesssys/constellation.git
synced 2024-12-17 20:04:36 -05:00
ci: build logcollector images
Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
parent
0a5c768088
commit
474f7ad356
@ -46,6 +46,7 @@ runs:
|
|||||||
type=raw,value=${{ inputs.pushTag }},enable=${{ '' != inputs.pushTag }}
|
type=raw,value=${{ inputs.pushTag }},enable=${{ '' != inputs.pushTag }}
|
||||||
type=raw,value=${{ steps.pseudo-version.outputs.pseudoVersion }},enable=${{ '' != steps.pseudo-version.outputs.pseudoVersion }}
|
type=raw,value=${{ steps.pseudo-version.outputs.pseudoVersion }},enable=${{ '' != steps.pseudo-version.outputs.pseudoVersion }}
|
||||||
type=ref,event=branch
|
type=ref,event=branch
|
||||||
|
|
||||||
- name: Log in to the Container registry
|
- name: Log in to the Container registry
|
||||||
id: docker-login
|
id: docker-login
|
||||||
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # tag=v2.1.0
|
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # tag=v2.1.0
|
||||||
|
39
.github/workflows/build-logcollector-images.yml
vendored
Normal file
39
.github/workflows/build-logcollector-images.yml
vendored
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
name: Build logcollector images
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
paths:
|
||||||
|
- "debugd/internal/debugd/logcollector/Makefile"
|
||||||
|
- "debugd/internal/debugd/logcollector/filebeat/**"
|
||||||
|
- "debugd/internal/debugd/logcollector/logstash/**"
|
||||||
|
- ".github/workflows/build-logcollector-images.yml"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-logcollector-images:
|
||||||
|
runs-on: ubuntu-22.04
|
||||||
|
permissions:
|
||||||
|
contents: read
|
||||||
|
packages: write
|
||||||
|
steps:
|
||||||
|
- name: Check out repository
|
||||||
|
id: checkout
|
||||||
|
uses: actions/checkout@93ea575cb5d8a053eaa0ac8fa3b40d7e05a33cc8 # tag=v3.1.0
|
||||||
|
with:
|
||||||
|
ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
|
- name: Build and upload logstash container image
|
||||||
|
uses: ./.github/actions/build_micro_service
|
||||||
|
with:
|
||||||
|
name: logstash-debugd
|
||||||
|
dockerfile: debugd/internal/debugd/logcollector/logstash/Dockerfile
|
||||||
|
githubToken: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Build and upload filebeat container image
|
||||||
|
uses: ./.github/actions/build_micro_service
|
||||||
|
with:
|
||||||
|
name: filebeat-debugd
|
||||||
|
dockerfile: debugd/internal/debugd/logcollector/filebeat/Dockerfile
|
||||||
|
githubToken: ${{ secrets.GITHUB_TOKEN }}
|
@ -11,6 +11,8 @@ on:
|
|||||||
- "kmsserver"
|
- "kmsserver"
|
||||||
- "verification-service"
|
- "verification-service"
|
||||||
- "qemu-metadata-api"
|
- "qemu-metadata-api"
|
||||||
|
- "filebeat-debug"
|
||||||
|
- "logstash-debug"
|
||||||
required: true
|
required: true
|
||||||
default: "join-service"
|
default: "join-service"
|
||||||
imageTag:
|
imageTag:
|
||||||
@ -53,6 +55,10 @@ jobs:
|
|||||||
echo "microServiceDockerfile=verify/Dockerfile" >> "$GITHUB_ENV" ;;
|
echo "microServiceDockerfile=verify/Dockerfile" >> "$GITHUB_ENV" ;;
|
||||||
"qemu-metadata-api" )
|
"qemu-metadata-api" )
|
||||||
echo "microServiceDockerfile=hack/qemu-metadata-api/Dockerfile" >> "$GITHUB_ENV" ;;
|
echo "microServiceDockerfile=hack/qemu-metadata-api/Dockerfile" >> "$GITHUB_ENV" ;;
|
||||||
|
"filebeat-debug" )
|
||||||
|
echo "microServiceDockerfile=debugd/internal/debugd/logcollector/filebeat/Dockerfile" >> "$GITHUB_ENV" ;;
|
||||||
|
"logstash-debug" )
|
||||||
|
echo "microServiceDockerfile=debugd/internal/debugd/logcollector/logstash/Dockerfile" >> "$GITHUB_ENV" ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
- name: Build and upload container image
|
- name: Build and upload container image
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
.PHONY: containers
|
|
||||||
|
|
||||||
containers:
|
|
||||||
docker build ./filebeat -t ghcr.io/edgelesssys/constellation/filebeat-debug
|
|
||||||
docker build ./logstash -t ghcr.io/edgelesssys/constellation/logstash-debug
|
|
||||||
docker push ghcr.io/edgelesssys/constellation/filebeat-debug
|
|
||||||
docker push ghcr.io/edgelesssys/constellation/logstash-debug
|
|
@ -1,8 +1,8 @@
|
|||||||
FROM fedora:37@sha256:f2c083c0b7d2367a375f15e002c2dc7baaca2b3181ace61f9d5113a8fe2f6b44
|
FROM fedora:37@sha256:f2c083c0b7d2367a375f15e002c2dc7baaca2b3181ace61f9d5113a8fe2f6b44 AS release
|
||||||
|
|
||||||
RUN dnf install -y https://artifacts.elastic.co/downloads/beats/filebeat/filebeat-8.5.0-x86_64.rpm systemd-devel
|
RUN dnf install -y https://artifacts.elastic.co/downloads/beats/filebeat/filebeat-8.5.0-x86_64.rpm systemd-devel
|
||||||
|
|
||||||
COPY filebeat.yml /usr/share/filebeat/filebeat.yml
|
COPY debugd/internal/debugd/logcollector/filebeat/filebeat.yml /usr/share/filebeat/filebeat.yml
|
||||||
|
|
||||||
RUN chmod 600 /usr/share/filebeat/filebeat.yml
|
RUN chmod 600 /usr/share/filebeat/filebeat.yml
|
||||||
|
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
FROM docker.io/opensearchproject/logstash-oss-with-opensearch-output-plugin:7.16.2
|
FROM docker.io/opensearchproject/logstash-oss-with-opensearch-output-plugin:7.16.2 AS release
|
||||||
|
|
||||||
RUN rm -f /usr/share/logstash/pipeline/logstash.conf
|
RUN rm -f /usr/share/logstash/pipeline/logstash.conf
|
||||||
|
|
||||||
COPY config/ /usr/share/logstash/config/
|
COPY debugd/internal/debugd/logcollector/logstash/config/ /usr/share/logstash/config/
|
||||||
|
|
||||||
COPY templates/ /usr/share/constellogs/templates/
|
COPY debugd/internal/debugd/logcollector/logstash/templates/ /usr/share/constellogs/templates/
|
||||||
|
|
||||||
ENTRYPOINT ["/usr/share/logstash/bin/logstash"]
|
ENTRYPOINT ["/usr/share/logstash/bin/logstash"]
|
||||||
|
Loading…
Reference in New Issue
Block a user