Skip to content

Latest commit

 

History

History
26 lines (19 loc) · 1.01 KB

README.md

File metadata and controls

26 lines (19 loc) · 1.01 KB

faas-cli-dind

Docker Cloud Automated build Docker Cloud Build Status

Docker image with faas-cli and Docker in Docker! Useful for CI/CD of OpenFaaS functions.

Usage with Gitlab CI

# .gitlab-ci.yml

stages:
    - build

build-and-deploy-function:
    stage: build
    image: "$DOCKER_REGISTRY_URL/thomas-anderson-bsl/faas-cli-dind:latest"
    script:
        - faas-cli build --tag=sha
        - echo -n "$DOCKER_REGISTRY_PASSWORD" | docker login --username "$DOCKER_REGISTRY_USERNAME" --password-stdin "$DOCKER_REGISTRY_URL"
        - faas-cli push --tag=sha
        - echo -n "$OPENFAAS_PASSWORD" | faas-cli login --gateway "$OPENFAAS_URL" --username "$OPENFAAS_USERNAME" --password-stdin
        - faas-cli deploy --gateway "$OPENFAAS_URL" --tag=sha --send-registry-auth