Motivation
Publish smaller containers, less time to download, less time to build, less CVEs, less deps
Modification
Use multi-stage syntax in Dockerfiles - requires docker >= 17.05
Tweak the automation.yaml to run on hosts that has the proper docker
version
Result
Smaller containers
Signed-off-by: Roy Golan <rgolan@redhat.com>
Motivation
The provisioner should allow thin/thick provisioning of disk, according
to what ovirt supports. Till now the support was through
'ovirtDiskFormat' parameter, and this is now dropped.
If a thin or thick disk is wanted, is is expected using a flag,
ovirtThinProvisioning, true by default.
Modification
- 'ovirtDiskFormat' parameter is dropped from the storage class
- 'ovirtDiskThinProvisioning' parameter, default true is expected.
The api will set the underlying disk format (raw/cow) according to the
storage domain tyep (iscsi/fc/nfs/cluster)
Result
For a thin provision disk, either don't pass nothing or
ovirtDiskThinProvioning=true
If the target ovirt storage domain is ISCSI or FC the disk format type
will be 'cow' and the sparse=true
If the target domain is NFS or Gluster the format is 'raw' and
sparse=true
For ovirtDiskProvisioning=false then the disk format is 'raw' and
sparse=false
fixes: #93
Signed-off-by: Roy Golan <rgolan@redhat.com>
The canonical name is now used in the provisioner code and expected to
be used everywhere:
- when creating a storage class, use "provisioner:
ovirt-volume-provisioner"
- when the a volume is created, a lable named "created-by:
ovirt-volume-provisioner will be used"
Examples under the examples directory have been updated accordingly.
Signed-off-by: Roy Golan <rgolan@redhat.com>
- base all containers on latest Centos 7.5.1804
- add multi labels according to atomic best practices
- name
- version
- release
- component
- summary
Signed-off-by: Roy Golan <rgolan@redhat.com>
The Makefile is even more generic now, clean, and easy to interact with
and extend.
The main targets are: build, build-containers, push-containers
Signed-off-by: Roy Golan <rgolan@redhat.com>
Due to latest APB updates, the extra vars passed are expected to be
called as textual json format {"key":"value"} rather then passing them
in the command line.
Signed-off-by: Roy Golan <rgolan@redhat.com>
All version will now drop the invalid "v" prefix which is used only to
mark a tag as a version tag.
The build and container creation was adjusted and also generelized to be
simpler, and controlled using variables
Signed-off-by: Roy Golan <rgolan@redhat.com>
This patch moves the mono-repo under rgolangh to here as
ovirt-cloudprovider.
- Makefile
- add build
- add container
- add rpm
- Compile against k8s 1.11 api (should be compatible with 1.10)
Signed-off-by: Roy Golan <rgolan@redhat.com>
Perform an atomic move of the folder into the kube volume plugin
directory so the controller will properly initilize it.
I have seen several times the how a initilization is failing and the
plugin isn't registered
Signed-off-by: Roy Golan <rgolan@redhat.com>
The flexvolume deployment container will now use OVIRT_VM_NAME env var
in order to set the ovirtVmName config item for the flexvolume driver.
Signed-off-by: Roy Golan <rgolan@redhat.com>
Using uid 1000 during the apb invocation using its containers makes sure
that it can see the mounted kubeconfig. This makes it possibly to push
both as a regular and root user.
Signed-off-by: Roy Golan <rgolan@redhat.com>
Fixes: #30
The apb deployment for the driver now copies the config file and the
binary to the (hostpath) kubernetes volume plugin directory on every
container start and that makes sure the latest binary and config is
loaded.
See ovirt-flexdriver/entrypoint.sh
Signed-off-by: Roy Golan <rgolan@redhat.com>
The project creates 3 container:
1. ovirt-flexvolume-driver
A container that exist to expose the binary, imediatly sleeps
forever. Used in a daemonset deployment - see the apb.
2. ovirt-volume-provisioner
A container for the provisioer controller. Used in a deployment - see
apb
3. ovirt-flexvolume-driver-apb
An apb container that will deploy both the driver and the provisioner.
One can use the service catalog to push the apb there and use it or
straight from the command line. See more in deployment/README.md
Its Makefile is currently under deployment/ovirt-flexvolume-driver/Makefile
- rename to ovirt-flexvolume-driver
- *-ansible continar is not replaced with apb
- remove the obsoleted 'binary' container
Signed-off-by: Roy Golan <rgolan@redhat.com>
- Deploy an APB container into your running openshift cluster (3.9)
see the Dockerfile generated by `apb prepare` under
deployment/ovirt-flexvolume-driver-apb/Dockerfile
- Pick the APB in the service-catalog to deploy the provisioner and
driver
see deployment/ovirt-flexvolume-driver-apb/playbooks/provision.yml
The APB will deploy both the flexvolume driver as a daemonset,
and the provisioner as a singleton deployment.
Build time requires apb tool to prepare an push the image.
Signed-off-by: Roy Golan <rgolan@redhat.com>
Fixes: https://github.com/rgolangh/ovirt-flexdriver/issues/16
The expected vars are documented in the playbook rather then specified
because they override the inventory one.
Signed-off-by: Roy Golan <rgolan@redhat.com>
The release and deployment is totally containerized now and is comprized
out of:
- ovirt-flexdriver-ansible - a container with the flexdriver binary that
consumes an inventory file and will deploy it on the nodes and masters
- ovirt-provisioner-ansible - a container that consumes an inventory and
deploys the ovirt-provisioner pod and all its dependent objects
- ovirt-provisioner - the actual pod that imlements the volume
provisioner api
Signed-off-by: Roy Golan <rgolan@redhat.com>
Motivation
Create an easy way to deploy both products by containerising the
deployment into a container, with Ansible playbook built in.
Modification
For provisioner create 2 separate containers - one is the binary, the
actual container application, and the other is 'deployer' which is a
container with and entrypoint that performs ansible playook invocation
Signed-off-by: Roy Golan <rgolan@redhat.com>
The included yaml files can deploy the provisioner (flex volume needs
ansible atm) plus:
- StorageClass
- Claim
- Test pod and an external volume
Fixes: #6
Signed-off-by: Roy Golan <rgolan@redhat.com>