Skip to content

Commit

Permalink
Merge branch 'main' into acceptance-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
domdom82 committed Jun 30, 2023
2 parents 8c3439a + 412531a commit 55b5873
Show file tree
Hide file tree
Showing 22 changed files with 865 additions and 94 deletions.
10 changes: 10 additions & 0 deletions .final_builds/packages/golang-1-linux/index.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
builds:
126fca7399cba5bc8c1b02e392441f1688daf1586d57d1b3614e314b893a6cc4:
version: 126fca7399cba5bc8c1b02e392441f1688daf1586d57d1b3614e314b893a6cc4
blobstore_id: 3be90446-c0f6-4aed-5b1b-da96e7d1814b
sha1: sha256:70c3918c28cd74a0a9be561b5eac8b85e8e7de4a72bc66cd321288974937e0be
8c04109541f4d504f5be559da433998bd459b0f45cd3654557cc3642cc4d2f60:
version: 8c04109541f4d504f5be559da433998bd459b0f45cd3654557cc3642cc4d2f60
blobstore_id: 07b1c4f5-6c91-4ef2-583b-f0ebf2b94b27
sha1: sha256:efdf65bca81264d9110ec764be7edea1de341781a1ffe59c219db064d71d9fc3
format-version: "2"
24 changes: 24 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
version: 2
updates:
- package-ecosystem: pip
directory: /ci/scripts
schedule:
interval: weekly
day: "monday"
time: "09:00"
timezone: "Europe/Berlin"
commit-message:
prefix: "ci"
labels:
- run-ci
- package-ecosystem: gomod
directory: /src/pcap
schedule:
interval: weekly
day: "monday"
time: "09:00"
timezone: "Europe/Berlin"
commit-message:
prefix: "dep"
labels:
- run-ci
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
# Dependency directories & default folders/files
.bundle
.dev_builds
.final_builds
pcap-release.tgz
config/private.yml
blobs
Expand Down
12 changes: 8 additions & 4 deletions ci/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Dockerfile for image cf-routing.common.repositories.cloud.sap/pcap-release-testflight:dev
# Dockerfile for image cf-routing.common.repositories.cloud.sap/pcap-release-testflight
FROM bosh/docker-cpi:main

ARG GINKGO_VERSION=latest
ARG GOLANGCILINT_VERSION=latest
RUN apt-get update && apt-get install -y libpcap-dev && rm -rf /var/lib/apt/lists/*
RUN apt-get update && apt-get install -y libpcap-dev python3-pip && rm -rf /var/lib/apt/lists/*

RUN curl -fsSL https://deb.nodesource.com/setup_current.x | sudo -E bash - && \
apt-get install -y nodejs && rm -rf /var/lib/apt/lists/*
Expand All @@ -14,8 +14,12 @@ RUN echo "source /tmp/local-bosh/director/env" >> /root/.bashrc
RUN npm install -g semantic-release && \
npm install -g @semantic-release/exec

# Install go dependencies
ENV GOBIN=/usr/local/bin
# Install Python libraries needed for scripts
COPY scripts/requirements.txt /requirements.txt
RUN /usr/bin/python3 -m pip install -r /requirements.txt

ENV GOPATH=/go PATH=${PATH}:/go/bin

RUN go install "github.com/onsi/ginkgo/v2/ginkgo@${GINKGO_VERSION}" \
&& go install "github.com/golangci/golangci-lint/cmd/golangci-lint@${GOLANGCILINT_VERSION}" \
&& go install "github.com/geofffranks/spruce/cmd/spruce@latest"
78 changes: 78 additions & 0 deletions ci/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ groups:
- rc
- acceptance-tests
- acceptance-tests-pr
- autobump-dependencies

jobs:
- name: unit-tests
Expand Down Expand Up @@ -286,6 +287,69 @@ jobs:
GITHUB_OWNER: cloudfoundry
GITHUB_TOKEN: ((github.access_token))
GCP_SERVICE_KEY: ((gcp.service_key))
- name: autobump-dependencies
public: true
serial: true
plan:
- do:
- get: daily
trigger: true
- get: git
- get: golang-release
- in_parallel:
steps:
- task: autobump-dependencies
config:
inputs:
- name: git
platform: linux
image_resource:
type: docker-image
source:
repository: cf-routing.common.repositories.cloud.sap/pcap-release-testflight
tag: latest
username: ((docker.username))
password: ((docker.password))
run:
dir: git
path: /usr/bin/python3
args: [ "ci/scripts/autobump-dependencies.py" ]
params:
REPO_ROOT: git
PR_BASE: main
PR_ORG: cloudfoundry
PR_LABEL: run-ci

GCP_SERVICE_KEY: ((gcp.service_key))
GITHUB_COM_TOKEN: ((github.access_token))
- task: autobump-golang-release
config:
inputs:
- name: git
- name: golang-release
platform: linux
image_resource:
type: docker-image
source:
repository: cf-routing.common.repositories.cloud.sap/pcap-release-testflight
tag: latest
username: ((docker.username))
password: ((docker.password))
run:
dir: git
path: /usr/bin/python3
args: [ "ci/scripts/bump_golang_vendored.py" ]
params:
GO_PACKAGE_REPO_ROOT: ../golang-release
REPO_ROOT: git
PR_BASE: main
PR_ORG: cloudfoundry
PR_LABEL: run-ci
GIT_AUTHOR_NAME: ((github.bot_user))
GIT_AUTHOR_EMAIL: ((github.bot_email))

GCP_SERVICE_KEY: ((gcp.service_key))
GITHUB_COM_TOKEN: ((github.access_token))

resource_types:
- name: slack-notification
Expand All @@ -310,6 +374,12 @@ resources:
uri: https://github.com/cloudfoundry/pcap-release.git
branch: main
password: ((github.access_token))
- name: golang-release
type: git
source:
uri: https://github.com/bosh-packages/golang-release.git
branch: master
password: ((github.access_token))

- name: git-pull-requests
type: pull-request
Expand All @@ -336,3 +406,11 @@ resources:
type: bosh-io-stemcell
source:
name: bosh-warden-boshlite-ubuntu-jammy-go_agent

- name: daily
type: time
source:
start: 7:00 AM
stop: 8:00 AM
location: Europe/Berlin
interval: 24h
Loading

0 comments on commit 55b5873

Please sign in to comment.