GitHub Actions work from peterbecich

This commit is contained in:
Peter Becich
2022-12-12 22:10:05 -08:00
committed by Tom McLaughlin
parent 116f01d327
commit f57082824b
8 changed files with 125 additions and 2 deletions

57
.github/workflows/ci.yml vendored Normal file
View File

@@ -0,0 +1,57 @@
on: [push]
name: CI
jobs:
Cabal_build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ghc:
- "8.10.7"
- "9.0.2"
- "9.2.7"
- "9.4.4"
name: Cabal GHC ${{ matrix.ghc }}
steps:
- uses: actions/checkout@v3
- name: Setup Haskell
uses: haskell/actions/setup@v2
with:
ghc-version: ${{ matrix.ghc }}
cabal-version: '3.8.1.0'
- run: cabal build all --enable-tests
- run: cabal test all
Stack_build:
name: Stack GHC ${{ matrix.ghc }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ghc:
- "8.10.7"
- "9.0.2"
- "9.2.7"
- "9.4.4"
steps:
- uses: actions/checkout@v3
- uses: haskell/actions/setup@v2
name: Setup Haskell Stack
with:
ghc-version: ${{ matrix.ghc }}
enable-stack: true
stack-version: "latest"
- uses: actions/cache@v3
name: Cache ~/.stack
with:
path: ~/.stack
key: ${{ runner.os }}-${{ matrix.ghc }}-stack
- name: Build
run: stack build --system-ghc --test --bench --no-run-tests --no-run-benchmarks
- name: Test
run: stack test --system-ghc

View File

@@ -1,5 +1,6 @@
# Kubernetes Haskell Client # Kubernetes Haskell Client
[![Stack and Cabal](https://github.com/kubernetes-client/haskell/actions/workflows/ci.yml/badge.svg)](https://github.com/kubernetes-client/haskell/actions/workflows/ci.yml)
[![Build Status](https://travis-ci.org/kubernetes-client/haskell.svg?branch=master)](https://travis-ci.org/kubernetes-client/haskell) [![Build Status](https://travis-ci.org/kubernetes-client/haskell.svg?branch=master)](https://travis-ci.org/kubernetes-client/haskell)
Haskell client for the [kubernetes](http://kubernetes.io/) API. Haskell client for the [kubernetes](http://kubernetes.io/) API.

4
cabal.project Normal file
View File

@@ -0,0 +1,4 @@
packages:
kubernetes
kubernetes-client
examples

1
examples/.gitignore vendored
View File

@@ -1,4 +1,3 @@
dist dist
dist-newstyle dist-newstyle
*.cabal
.stack-work .stack-work

View File

@@ -0,0 +1,54 @@
cabal-version: 1.12
-- This file has been generated from package.yaml by hpack version 0.34.4.
--
-- see: https://github.com/sol/hpack
name: kubernetes-examples
version: 0.1.0.1
synopsis: Kubernetes examples with Haskell
description: Examples to interact with Kubernetes using kubernetes-client and kubernetes-client-core
category: Examples, Kubernetes
maintainer: Shimin Guo <smguo2001@gmail.com>,
Akshay Mankar <itsakshaymankar@gmail.com>
license: Apache-2.0
license-file: LICENSE
build-type: Simple
executable in-cluster
main-is: Main.hs
other-modules:
Paths_kubernetes_examples
hs-source-dirs:
in-cluster
ghc-options: -Wall
build-depends:
base <5
, containers
, http-client
, http-types
, kubernetes-client
, kubernetes-client-core
, safe-exceptions
, stm
, text
default-language: Haskell2010
executable simple
main-is: Main.hs
other-modules:
Paths_kubernetes_examples
hs-source-dirs:
simple
ghc-options: -Wall
build-depends:
base <5
, containers
, http-client
, http-types
, kubernetes-client
, kubernetes-client-core
, safe-exceptions
, stm
, text
default-language: Haskell2010

View File

@@ -22,7 +22,7 @@ executables:
ghc-options: ghc-options:
- -Wall - -Wall
dependencies: dependencies:
- base - base < 5
- containers - containers
- http-client - http-client
- http-types - http-types

View File

@@ -44,6 +44,8 @@ library
hs-source-dirs: hs-source-dirs:
src src
ghc-options: -Wall ghc-options: -Wall
build-tool-depends:
hspec-discover:hspec-discover
build-depends: build-depends:
aeson >=1.2 && <3 aeson >=1.2 && <3
, attoparsec >=0.13 , attoparsec >=0.13
@@ -88,6 +90,8 @@ test-suite example
Paths_kubernetes_client Paths_kubernetes_client
hs-source-dirs: hs-source-dirs:
example example
build-tool-depends:
hspec-discover:hspec-discover
build-depends: build-depends:
aeson >=1.2 && <3 aeson >=1.2 && <3
, attoparsec >=0.13 , attoparsec >=0.13
@@ -138,6 +142,8 @@ test-suite spec
Paths_kubernetes_client Paths_kubernetes_client
hs-source-dirs: hs-source-dirs:
test test
build-tool-depends:
hspec-discover:hspec-discover
build-depends: build-depends:
aeson >=1.2 && <3 aeson >=1.2 && <3
, attoparsec >=0.13 , attoparsec >=0.13

View File

@@ -15,6 +15,8 @@ library:
source-dirs: src source-dirs: src
ghc-options: ghc-options:
- -Wall - -Wall
build-tools:
- hspec-discover
tests: tests:
spec: spec:
main: Spec.hs main: Spec.hs