Skip to content

Commit

Permalink
created action
Browse files Browse the repository at this point in the history
  • Loading branch information
scott-paige committed Feb 22, 2020
1 parent 9b67158 commit f8eabb9
Show file tree
Hide file tree
Showing 3 changed files with 30 additions and 0 deletions.
15 changes: 15 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
FROM alpine

RUN apk add --update --no-cache \
ca-certificates \
wget \
bash

RUN wget https://github.com/concourse/concourse/releases/download/v5.8.0/fly-5.8.0-linux-amd64.tgz && \
tar xf fly*.tgz -C /usr/local/bin/ && \
chmod +x /usr/local/bin/fly

COPY entrypoint.sh /entrypoint.sh

CMD ["sh", "/entrypoint.sh"]

5 changes: 5 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
name: Validate Pipeline
description: "Validate pipeline yamls"
runs:
using: 'docker'
image: 'Dockerfile'
10 changes: 10 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

set -eu

validator="$(fly5 -t cc validate-pipeline -c ci/config/pipelines/aws-prod/deploy-pipeline.yml)"

if [[ $validator != *"looks good"* ]]; then
command || exit 1
fi

0 comments on commit f8eabb9

Please sign in to comment.