From 9ed260916ab48f07684c43b82288eb48c984c47e Mon Sep 17 00:00:00 2001 From: Albert Esteve Date: Wed, 7 Sep 2022 09:07:51 +0200 Subject: [PATCH] reuse: addheader GPL remaining python Add GLP copyright header in all remaining python files in the project, either those with the .py extension in folders other than lib or tests, or files with the python shebang. Signed-off-by: Albert Esteve --- build-aux/vercmp | 22 +++-------------- contrib/block | 19 ++------------- contrib/extend-stats | 22 +++-------------- contrib/git-sync | 22 +++-------------- contrib/logdb | 22 +++-------------- contrib/logstat | 22 +++-------------- contrib/lvs-stats | 22 +++-------------- contrib/nfs-check.py | 17 ++----------- contrib/profile-stats | 22 +++-------------- contrib/refmt | 22 +++-------------- contrib/repoplot | 22 +++-------------- contrib/repostat | 23 ++++-------------- contrib/runvm | 21 +++------------- contrib/target | 22 +++-------------- doc/conf.py | 3 +++ helpers/fallocate | 21 +++------------- helpers/kvm2ovirt | 22 ++++------------- init/daemonAdapter | 23 ++++-------------- lib/dnf-plugins/vdsmupgrade.py | 20 ++-------------- lib/vdsm/storage/curl-img-wrap | 22 +++-------------- lib/vdsm/storage/fc-scan | 22 +++-------------- lib/vdsm/storage/managedvolume-helper | 23 ++++-------------- lib/vdsmclient/client.py | 22 +++-------------- lib/yajsonrpc/__init__.py | 19 ++++----------- lib/yajsonrpc/betterAsyncore.py | 17 +++---------- lib/yajsonrpc/exception.py | 17 +++---------- lib/yajsonrpc/jsonrpcclient.py | 17 +++---------- lib/yajsonrpc/stomp.py | 18 +++----------- lib/yajsonrpc/stompclient.py | 17 +++---------- lib/yajsonrpc/stompserver.py | 16 ++----------- static/libexec/vdsm/get-conf-item | 3 +++ static/libexec/vdsm/sitecustomize.py | 3 +++ static/libexec/vdsm/supervdsmd | 22 ++++------------- static/libexec/vdsm/vdsmd | 12 ++++------ static/usr/bin/vdsm-client | 23 ++++-------------- static/usr/bin/vdsm-tool | 22 ++++------------- tests/profile | 4 ++++ tests/profile-analyze | 4 ++++ tests/py-watch | 3 +++ .../allocate_net/before_device_create.py | 22 +++-------------- vdsm_hooks/boot_hostdev/before_vm_start.py | 22 +++-------------- vdsm_hooks/checkimages/before_vm_start.py | 3 +++ vdsm_hooks/checkips/after_get_stats.py | 23 ++++-------------- vdsm_hooks/checkips/checkips_utils.py | 22 +++-------------- vdsm_hooks/checkips/checkipsd | 23 ++++-------------- vdsm_hooks/cpuflags/before_vm_start.py | 22 +++-------------- vdsm_hooks/diskunmap/before_vm_start.py | 22 +++-------------- vdsm_hooks/ethtool_options/ethtool_options.py | 21 +++------------- vdsm_hooks/extnet/extnet_vnic.py | 4 ++++ .../extra_ipv4_addrs/extra_ipv4_addrs.py | 21 +++------------- .../fakevmstats/after_get_all_vm_stats.py | 22 +++-------------- vdsm_hooks/faqemu/after_get_caps.py | 22 +++-------------- vdsm_hooks/faqemu/before_vm_start.py | 22 +++-------------- vdsm_hooks/fcoe/fcoe_before_network_setup.py | 3 +++ vdsm_hooks/fileinject/before_vm_start.py | 3 +++ vdsm_hooks/httpsisoboot/before_vm_start.py | 3 +++ vdsm_hooks/localdisk/after_disk_prepare | 23 ++++-------------- vdsm_hooks/localdisk/before_vm_migrate_source | 23 ++++-------------- vdsm_hooks/localdisk/localdisk-helper | 23 ++++-------------- vdsm_hooks/log_console/before_vm_start.py | 22 +++-------------- vdsm_hooks/log_firmware/before_vm_start.py | 22 +++-------------- vdsm_hooks/macbind/before_vm_start.py | 22 +++-------------- vdsm_hooks/nestedvt/before_vm_start.py | 23 ++++-------------- .../openstacknet/after_device_create.py | 3 +++ vdsm_hooks/openstacknet/after_get_caps.py | 22 +++-------------- vdsm_hooks/openstacknet/after_vm_start.py | 3 +++ .../openstacknet/before_device_create.py | 3 +++ vdsm_hooks/openstacknet/openstacknet_utils.py | 3 +++ vdsm_hooks/qemucmdline/before_vm_start.py | 24 ++++--------------- vdsm_hooks/scratchpad/after_vm_destroy.py | 3 +++ .../scratchpad/before_vm_migrate_source.py | 3 +++ vdsm_hooks/scratchpad/before_vm_start.py | 3 +++ vdsm_hooks/smbios/before_vm_start.py | 3 +++ vdsm_hooks/spiceoptions/before_vm_start.py | 3 +++ vdsm_hooks/vhostmd/after_vm_destroy.py | 23 ++++-------------- vdsm_hooks/vhostmd/before_vm_start.py | 22 +++-------------- vdsm_hooks/vmfex_dev/vmfex_vnic.py | 22 +++-------------- 77 files changed, 249 insertions(+), 1024 deletions(-) diff --git a/build-aux/vercmp b/build-aux/vercmp index 70e59c21c1..867a9c4f6d 100755 --- a/build-aux/vercmp +++ b/build-aux/vercmp @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2016 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later from __future__ import absolute_import diff --git a/contrib/block b/contrib/block index dd90e39a4d..125667f2db 100755 --- a/contrib/block +++ b/contrib/block @@ -1,22 +1,7 @@ #!/usr/bin/python3 # -# Copyright 2020 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later # # This script blocks access to a certain port on a server temporarily. This is # useful for testing recovery flows when storage server is not accessible. diff --git a/contrib/extend-stats b/contrib/extend-stats index 92174322f2..274ccf563b 100755 --- a/contrib/extend-stats +++ b/contrib/extend-stats @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2014 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Compute extend stats from vdsm log. diff --git a/contrib/git-sync b/contrib/git-sync index 2bba2300e8..e3e5f6f89a 100755 --- a/contrib/git-sync +++ b/contrib/git-sync @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2020 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Push a git branch to remote, modifying the remote working directory. diff --git a/contrib/logdb b/contrib/logdb index 51d6da5fa2..574f1dd551 100755 --- a/contrib/logdb +++ b/contrib/logdb @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2015 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Usage: logdb dbname logfile ... diff --git a/contrib/logstat b/contrib/logstat index b3f28e04d5..e743aad853 100755 --- a/contrib/logstat +++ b/contrib/logstat @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2016 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Usage: logstat logfile ... diff --git a/contrib/lvs-stats b/contrib/lvs-stats index c426c68ab7..631e5b6d01 100755 --- a/contrib/lvs-stats +++ b/contrib/lvs-stats @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2017 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Analayze lvs info from sosreport. diff --git a/contrib/nfs-check.py b/contrib/nfs-check.py index 21e15cacac..c8d00b4d95 100644 --- a/contrib/nfs-check.py +++ b/contrib/nfs-check.py @@ -1,18 +1,5 @@ -# Copyright 2012 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later from __future__ import print_function from __future__ import absolute_import diff --git a/contrib/profile-stats b/contrib/profile-stats index 21c687c7df..77d9128c5b 100755 --- a/contrib/profile-stats +++ b/contrib/profile-stats @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2014 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Print statistics from recorded profile using pstat format. diff --git a/contrib/refmt b/contrib/refmt index 794a17ad91..f929be39d1 100755 --- a/contrib/refmt +++ b/contrib/refmt @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2016 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later # # helper script to prettify Vdsm parameter dumps from the logs. # useful to extract test data. diff --git a/contrib/repoplot b/contrib/repoplot index 1f2a2c048f..94b17803b1 100755 --- a/contrib/repoplot +++ b/contrib/repoplot @@ -1,23 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2014 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later """ Parse repoStats log lines and plot graphs of lastCheck and read delay for all diff --git a/contrib/repostat b/contrib/repostat index 480729e1af..345d1dd404 100755 --- a/contrib/repostat +++ b/contrib/repostat @@ -1,23 +1,8 @@ #!/usr/bin/python3 -# -# Copyright 2015-2018 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license -# + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later + """ Parse repoStats log lines and calculate statistics. diff --git a/contrib/runvm b/contrib/runvm index c9662fa771..8d2cccd8e5 100755 --- a/contrib/runvm +++ b/contrib/runvm @@ -1,22 +1,7 @@ #!/usr/bin/python3 -# -# Copyright 2016-2017 Red Hat, Inc. -# -# This program 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 2 of the License, or -# (at your option) any later version. -# -# This program 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 this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA -# -# Refer to the README and COPYING files for full details of the license + +# SPDX-FileCopyrightText: Red Hat, Inc. +# SPDX-License-Identifier: GPL-2.0-or-later # cat <