#!/usr/bin/python3.13

# Copyright 2023 SUSE LLC
#
# This file is part of instance-billing-flavor-check
#
# instance-billing-flavor-check is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# instance-billing-flavor-check is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along with
# instance-billing-flavor-check. If not, see <http://www.gnu.org/licenses/>.

import os
import sys

if os.geteuid():
    # Need to be root in Azure because we read from a specific area of the disc
    # and the log file location
    sys.exit('You must be root')

from instance_billing_flavor_check.utils import check_payg_byos

flavor = check_payg_byos()
print(flavor[0])
sys.exit(flavor[1])
