The number of scientific communities needing access to large amounts of computing resources for their research work is growing. These demands are largely satisfied by grid computing infrastructures providing a unified access to resources distributed all over the world. A growing portion of those resources are provided as private clouds. These sites have different access protocols compared to traditional grid computing elements and can include more specialized capacities, for example, virtual machines with GPU accelerators, increased memory, etc. Therefore, there is a need to provide users with a uniform interface to access both grid and cloud resources. DIRAC is a project developing tools and services for the users of distributed computing resources. The DIRAC Workload Management Service allows to handle user jobs that can run on traditional computing clusters but also on cloud sites transparently. The service is provided by several large grid infrastructure projects, for example, EGI, GridPP, and others. In this contribution we will describe the DIRAC subsystem for managing cloud resources, mechanisms for creation and managing the life cycle of the virtual machines, secure access to clouds based on the OAuth2/OIDC tokens technology. We will give examples of cloud usage by research communities of users of GridPP and EGI grids.