chore: Add docker image

Signed-off-by: Arthur Amstutz <arthur.amstutz@corp.ovh.com>
This commit is contained in:
Arthur Amstutz 2025-09-19 06:45:23 +00:00
parent cf098f03d0
commit 7f39388305
No known key found for this signature in database
GPG key ID: F3C6FC59C43A6EF6
3 changed files with 31 additions and 2 deletions

View file

@ -29,9 +29,15 @@ jobs:
if-no-files-found: error
push-docker-image:
needs:
- build
- build-wasm
runs-on: library/default-vm
steps:
- uses: actions/checkout
- uses: actions/downloadArtifact
with:
name: ovhcloud
- run: docker build -t ovhcloud-cli/ovhcloud .
- uses: actions/dockerPush
with:
@ -40,8 +46,6 @@ jobs:
release:
needs:
- build
- build-wasm
- push-docker-image
if: git.ref_name == 'main'
runs-on:

13
Dockerfile Normal file
View file

@ -0,0 +1,13 @@
FROM alpine:latest
VOLUME ["/config"]
WORKDIR /config
RUN apk update && \
apk add --no-cache tzdata ca-certificates && \
rm -rf /var/cache/apk/*
COPY ./ovhcloud /usr/local/bin/ovhcloud
ENTRYPOINT ["ovhcloud"]
CMD ["--help"]

View file

@ -11,6 +11,8 @@
# Table of Contents
- [Installation](#installation)
- [Binary download](#binary-download)
- [Run with Docker](#run-with-docker)
- [Usage](#usage)
- [Authenticating the CLI](#authenticating-the-cli)
- [Examples](#examples)
@ -23,10 +25,20 @@
# Installation
## Binary download
1. Download [latest release](https://github.com/ovh/ovhcloud-cli/releases/latest)
2. Untar / unzip the archive
3. Add the containing folder to your `PATH` environment variable
## Run with Docker
You can also run the CLI using Docker:
```bash
docker run -it --rm -v ovhcloud-cli-config-files:/config ovhcom/ovhcloud-cli login
```
# Usage
```bash