#include "common.h"

namespace NRTYDeploy {
    bool GetCTypesFromStorage(const NSaas::IVersionedStorage& storage, TVector<TString>& ctypes) {
        TVector<TString> variants;
        if (storage.GetNodes("common/", variants, true)) {
            ctypes.clear();
            for (ui32 i = 0; i < variants.size(); ++i) {
                if (storage.ExistsNode("common/" + variants[i] + "/cluster.meta")) {
                    ctypes.push_back(variants[i]);
                }
            }
            return true;
        }
        return false;
    }
}
