Full Code of crops/yocto-dockerfiles for AI

master c003de7d2290 cached
33 files
88.0 KB
24.1k tokens
19 symbols
1 requests
Download .txt
Repository: crops/yocto-dockerfiles
Branch: master
Commit: c003de7d2290
Files: 33
Total size: 88.0 KB

Directory structure:
gitextract_1r_6ch8g/

├── .github/
│   └── workflows/
│       └── build-test-deploy.yml
├── .gitignore
├── COPYING
├── LICENSE
├── README.md
├── build-install-dumb-init.sh
├── build_container.sh
├── buildall.sh
├── deploy.sh
├── distro-entry.sh
├── dockerfiles/
│   ├── alma/
│   │   ├── alma-8/
│   │   │   └── alma-8-base/
│   │   │       └── Dockerfile
│   │   └── alma-9/
│   │       └── alma-9-base/
│   │           └── Dockerfile
│   ├── debian/
│   │   ├── debian-10/
│   │   │   └── debian-10-base/
│   │   │       └── Dockerfile
│   │   ├── debian-11/
│   │   │   └── debian-11-base/
│   │   │       └── Dockerfile
│   │   └── debian-12/
│   │       └── debian-12-base/
│   │           └── Dockerfile
│   ├── fedora/
│   │   ├── fedora-39/
│   │   │   └── fedora-39-base/
│   │   │       └── Dockerfile
│   │   └── fedora-40/
│   │       └── fedora-40-base/
│   │           └── Dockerfile
│   ├── opensuse/
│   │   ├── opensuse-15.4/
│   │   │   └── opensuse-15.4-base/
│   │   │       └── Dockerfile
│   │   ├── opensuse-15.5/
│   │   │   └── opensuse-15.5-base/
│   │   │       └── Dockerfile
│   │   └── opensuse-15.6/
│   │       └── opensuse-15.6-base/
│   │           └── Dockerfile
│   ├── templates/
│   │   └── Dockerfile.builder
│   └── ubuntu/
│       ├── ubuntu-18.04/
│       │   └── ubuntu-18.04-base/
│       │       └── Dockerfile
│       ├── ubuntu-20.04/
│       │   └── ubuntu-20.04-base/
│       │       └── Dockerfile
│       ├── ubuntu-22.04/
│       │   └── ubuntu-22.04-base/
│       │       └── Dockerfile
│       └── ubuntu-24.04/
│           └── ubuntu-24.04-base/
│               └── Dockerfile
├── helpers/
│   └── runbitbake.py
├── install-buildtools-make.sh
├── install-buildtools.sh
└── tests/
    ├── container/
    │   ├── smoke.sh
    │   ├── vnc-in-container-test.sh
    │   └── vnc-test.sh
    └── unit/
        ├── signals/
        │   └── bitbake
        └── test_runbitbake.py

================================================
FILE CONTENTS
================================================

================================================
FILE: .github/workflows/build-test-deploy.yml
================================================
name: yocto-container build and test
on:
  push:
    branches:
      - master
  pull_request:

  # Allow for manually running
  workflow_dispatch:

  # Run at 00:52 UTC every Saturday
  schedule:
    - cron: '52 0 * * 6'

jobs:
  build-test-deploy:
    runs-on: ubuntu-latest
    permissions:
      packages: write
    strategy:
      fail-fast: false
      matrix:
        distro_to_build: [
          alma-8,
          alma-9,
          debian-10,
          debian-11,
          debian-12,
          fedora-39,
          fedora-40,
          opensuse-15.4,
          opensuse-15.5,
          opensuse-15.6,
          ubuntu-18.04,
          ubuntu-20.04,
          ubuntu-22.04,
          ubuntu-24.04
        ]
        targetplatform: [
          linux/amd64
        ]
    env:
      DISTRO_TO_BUILD: ${{ matrix.distro_to_build }}
      TARGETPLATFORM: ${{ matrix.targetplatform }}
      REPO: crops/yocto
      DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
      DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
      GHCR_USERNAME: ${{ github.actor }}
      GHCR_PASSWORD: ${{ secrets.GITHUB_TOKEN }}

    steps:
      - uses: actions/checkout@v4

      # Build and test the images
      - name: Run build-and-test.sh
        run: ./build_container.sh

      # Deploy the images
      - name: Deploy
        if: ${{ env.DOCKER_PASSWORD != '' && env.GHCR_PASSWORD != '' }}
        run: ./deploy.sh


================================================
FILE: .gitignore
================================================
dockerfiles/*/*/*-builder/Dockerfile
*.pyc
*.pyo
*.orig
*.rej
*~


================================================
FILE: COPYING
================================================
                    GNU GENERAL PUBLIC LICENSE
                       Version 2, June 1991

 Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 Everyone is permitted to copy and distribute verbatim copies
 of this license document, but changing it is not allowed.

                            Preamble

  The licenses for most software are designed to take away your
freedom to share and change it.  By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users.  This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it.  (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.)  You can apply it to
your programs, too.

  When we speak of free software, we are referring to freedom, not
price.  Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.

  To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.

  For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have.  You must make sure that they, too, receive or can get the
source code.  And you must show them these terms so they know their
rights.

  We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.

  Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software.  If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.

  Finally, any free program is threatened constantly by software
patents.  We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary.  To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.

  The precise terms and conditions for copying, distribution and
modification follow.

                    GNU GENERAL PUBLIC LICENSE
   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

  0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License.  The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language.  (Hereinafter, translation is included without limitation in
the term "modification".)  Each licensee is addressed as "you".

Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope.  The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.

  1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.

You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.

  2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:

    a) You must cause the modified files to carry prominent notices
    stating that you changed the files and the date of any change.

    b) You must cause any work that you distribute or publish, that in
    whole or in part contains or is derived from the Program or any
    part thereof, to be licensed as a whole at no charge to all third
    parties under the terms of this License.

    c) If the modified program normally reads commands interactively
    when run, you must cause it, when started running for such
    interactive use in the most ordinary way, to print or display an
    announcement including an appropriate copyright notice and a
    notice that there is no warranty (or else, saying that you provide
    a warranty) and that users may redistribute the program under
    these conditions, and telling the user how to view a copy of this
    License.  (Exception: if the Program itself is interactive but
    does not normally print such an announcement, your work based on
    the Program is not required to print an announcement.)

These requirements apply to the modified work as a whole.  If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works.  But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.

Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.

In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.

  3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:

    a) Accompany it with the complete corresponding machine-readable
    source code, which must be distributed under the terms of Sections
    1 and 2 above on a medium customarily used for software interchange; or,

    b) Accompany it with a written offer, valid for at least three
    years, to give any third party, for a charge no more than your
    cost of physically performing source distribution, a complete
    machine-readable copy of the corresponding source code, to be
    distributed under the terms of Sections 1 and 2 above on a medium
    customarily used for software interchange; or,

    c) Accompany it with the information you received as to the offer
    to distribute corresponding source code.  (This alternative is
    allowed only for noncommercial distribution and only if you
    received the program in object code or executable form with such
    an offer, in accord with Subsection b above.)

The source code for a work means the preferred form of the work for
making modifications to it.  For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable.  However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.

If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.

  4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License.  Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.

  5. You are not required to accept this License, since you have not
signed it.  However, nothing else grants you permission to modify or
distribute the Program or its derivative works.  These actions are
prohibited by law if you do not accept this License.  Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.

  6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions.  You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.

  7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License.  If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all.  For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.

If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.

It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices.  Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.

This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.

  8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded.  In such case, this License incorporates
the limitation as if written in the body of this License.

  9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time.  Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.

Each version is given a distinguishing version number.  If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation.  If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.

  10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission.  For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this.  Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.

                            NO WARRANTY

  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.

  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

                     END OF TERMS AND CONDITIONS

            How to Apply These Terms to Your New Programs

  If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.

  To do so, attach the following notices to the program.  It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.

    <one line to give the program's name and a brief idea of what it does.>
    Copyright (C) <year>  <name of author>

    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.

Also add information on how to contact you by electronic and paper mail.

If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:

    Gnomovision version 69, Copyright (C) year name of author
    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
    This is free software, and you are welcome to redistribute it
    under certain conditions; type `show c' for details.

The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License.  Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.

You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary.  Here is a sample; alter the names:

  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
  `Gnomovision' (which makes passes at compilers) written by James Hacker.

  <signature of Ty Coon>, 1 April 1989
  Ty Coon, President of Vice

This General Public License does not permit incorporating your program into
proprietary programs.  If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library.  If this is what you want to do, use the GNU Lesser General
Public License instead of this License.


================================================
FILE: LICENSE
================================================
                    GNU GENERAL PUBLIC LICENSE
                       Version 2, June 1991

 Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 Everyone is permitted to copy and distribute verbatim copies
 of this license document, but changing it is not allowed.

                            Preamble

  The licenses for most software are designed to take away your
freedom to share and change it.  By contrast, the GNU General Public
License is intended to guarantee your freedom to share and change free
software--to make sure the software is free for all its users.  This
General Public License applies to most of the Free Software
Foundation's software and to any other program whose authors commit to
using it.  (Some other Free Software Foundation software is covered by
the GNU Lesser General Public License instead.)  You can apply it to
your programs, too.

  When we speak of free software, we are referring to freedom, not
price.  Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.

  To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if you
distribute copies of the software, or if you modify it.

  For example, if you distribute copies of such a program, whether
gratis or for a fee, you must give the recipients all the rights that
you have.  You must make sure that they, too, receive or can get the
source code.  And you must show them these terms so they know their
rights.

  We protect your rights with two steps: (1) copyright the software, and
(2) offer you this license which gives you legal permission to copy,
distribute and/or modify the software.

  Also, for each author's protection and ours, we want to make certain
that everyone understands that there is no warranty for this free
software.  If the software is modified by someone else and passed on, we
want its recipients to know that what they have is not the original, so
that any problems introduced by others will not reflect on the original
authors' reputations.

  Finally, any free program is threatened constantly by software
patents.  We wish to avoid the danger that redistributors of a free
program will individually obtain patent licenses, in effect making the
program proprietary.  To prevent this, we have made it clear that any
patent must be licensed for everyone's free use or not licensed at all.

  The precise terms and conditions for copying, distribution and
modification follow.

                    GNU GENERAL PUBLIC LICENSE
   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

  0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License.  The "Program", below,
refers to any such program or work, and a "work based on the Program"
means either the Program or any derivative work under copyright law:
that is to say, a work containing the Program or a portion of it,
either verbatim or with modifications and/or translated into another
language.  (Hereinafter, translation is included without limitation in
the term "modification".)  Each licensee is addressed as "you".

Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope.  The act of
running the Program is not restricted, and the output from the Program
is covered only if its contents constitute a work based on the
Program (independent of having been made by running the Program).
Whether that is true depends on what the Program does.

  1. You may copy and distribute verbatim copies of the Program's
source code as you receive it, in any medium, provided that you
conspicuously and appropriately publish on each copy an appropriate
copyright notice and disclaimer of warranty; keep intact all the
notices that refer to this License and to the absence of any warranty;
and give any other recipients of the Program a copy of this License
along with the Program.

You may charge a fee for the physical act of transferring a copy, and
you may at your option offer warranty protection in exchange for a fee.

  2. You may modify your copy or copies of the Program or any portion
of it, thus forming a work based on the Program, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:

    a) You must cause the modified files to carry prominent notices
    stating that you changed the files and the date of any change.

    b) You must cause any work that you distribute or publish, that in
    whole or in part contains or is derived from the Program or any
    part thereof, to be licensed as a whole at no charge to all third
    parties under the terms of this License.

    c) If the modified program normally reads commands interactively
    when run, you must cause it, when started running for such
    interactive use in the most ordinary way, to print or display an
    announcement including an appropriate copyright notice and a
    notice that there is no warranty (or else, saying that you provide
    a warranty) and that users may redistribute the program under
    these conditions, and telling the user how to view a copy of this
    License.  (Exception: if the Program itself is interactive but
    does not normally print such an announcement, your work based on
    the Program is not required to print an announcement.)

These requirements apply to the modified work as a whole.  If
identifiable sections of that work are not derived from the Program,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works.  But when you
distribute the same sections as part of a whole which is a work based
on the Program, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote it.

Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Program.

In addition, mere aggregation of another work not based on the Program
with the Program (or with a work based on the Program) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.

  3. You may copy and distribute the Program (or a work based on it,
under Section 2) in object code or executable form under the terms of
Sections 1 and 2 above provided that you also do one of the following:

    a) Accompany it with the complete corresponding machine-readable
    source code, which must be distributed under the terms of Sections
    1 and 2 above on a medium customarily used for software interchange; or,

    b) Accompany it with a written offer, valid for at least three
    years, to give any third party, for a charge no more than your
    cost of physically performing source distribution, a complete
    machine-readable copy of the corresponding source code, to be
    distributed under the terms of Sections 1 and 2 above on a medium
    customarily used for software interchange; or,

    c) Accompany it with the information you received as to the offer
    to distribute corresponding source code.  (This alternative is
    allowed only for noncommercial distribution and only if you
    received the program in object code or executable form with such
    an offer, in accord with Subsection b above.)

The source code for a work means the preferred form of the work for
making modifications to it.  For an executable work, complete source
code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to
control compilation and installation of the executable.  However, as a
special exception, the source code distributed need not include
anything that is normally distributed (in either source or binary
form) with the major components (compiler, kernel, and so on) of the
operating system on which the executable runs, unless that component
itself accompanies the executable.

If distribution of executable or object code is made by offering
access to copy from a designated place, then offering equivalent
access to copy the source code from the same place counts as
distribution of the source code, even though third parties are not
compelled to copy the source along with the object code.

  4. You may not copy, modify, sublicense, or distribute the Program
except as expressly provided under this License.  Any attempt
otherwise to copy, modify, sublicense or distribute the Program is
void, and will automatically terminate your rights under this License.
However, parties who have received copies, or rights, from you under
this License will not have their licenses terminated so long as such
parties remain in full compliance.

  5. You are not required to accept this License, since you have not
signed it.  However, nothing else grants you permission to modify or
distribute the Program or its derivative works.  These actions are
prohibited by law if you do not accept this License.  Therefore, by
modifying or distributing the Program (or any work based on the
Program), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Program or works based on it.

  6. Each time you redistribute the Program (or any work based on the
Program), the recipient automatically receives a license from the
original licensor to copy, distribute or modify the Program subject to
these terms and conditions.  You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
this License.

  7. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License.  If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Program at all.  For example, if a patent
license would not permit royalty-free redistribution of the Program by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Program.

If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply and the section as a whole is intended to apply in other
circumstances.

It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system, which is
implemented by public license practices.  Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.

This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.

  8. If the distribution and/or use of the Program is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Program under this License
may add an explicit geographical distribution limitation excluding
those countries, so that distribution is permitted only in or among
countries not thus excluded.  In such case, this License incorporates
the limitation as if written in the body of this License.

  9. The Free Software Foundation may publish revised and/or new versions
of the General Public License from time to time.  Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.

Each version is given a distinguishing version number.  If the Program
specifies a version number of this License which applies to it and "any
later version", you have the option of following the terms and conditions
either of that version or of any later version published by the Free
Software Foundation.  If the Program does not specify a version number of
this License, you may choose any version ever published by the Free Software
Foundation.

  10. If you wish to incorporate parts of the Program into other free
programs whose distribution conditions are different, write to the author
to ask for permission.  For software which is copyrighted by the Free
Software Foundation, write to the Free Software Foundation; we sometimes
make exceptions for this.  Our decision will be guided by the two goals
of preserving the free status of all derivatives of our free software and
of promoting the sharing and reuse of software generally.

                            NO WARRANTY

  11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW.  EXCEPT WHEN
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.  THE ENTIRE RISK AS
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU.  SHOULD THE
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
REPAIR OR CORRECTION.

  12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.

                     END OF TERMS AND CONDITIONS

            How to Apply These Terms to Your New Programs

  If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.

  To do so, attach the following notices to the program.  It is safest
to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.

    <one line to give the program's name and a brief idea of what it does.>
    Copyright (C) <year>  <name of author>

    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.

Also add information on how to contact you by electronic and paper mail.

If the program is interactive, make it output a short notice like this
when it starts in an interactive mode:

    Gnomovision version 69, Copyright (C) year name of author
    Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
    This is free software, and you are welcome to redistribute it
    under certain conditions; type `show c' for details.

The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License.  Of course, the commands you use may
be called something other than `show w' and `show c'; they could even be
mouse-clicks or menu items--whatever suits your program.

You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the program, if
necessary.  Here is a sample; alter the names:

  Yoyodyne, Inc., hereby disclaims all copyright interest in the program
  `Gnomovision' (which makes passes at compilers) written by James Hacker.

  <signature of Ty Coon>, 1 April 1989
  Ty Coon, President of Vice

This General Public License does not permit incorporating your program into
proprietary programs.  If your program is a subroutine library, you may
consider it more useful to permit linking proprietary applications with the
library.  If this is what you want to do, use the GNU Lesser General
Public License instead of this License.


================================================
FILE: README.md
================================================
# yocto-docker


================================================
FILE: build-install-dumb-init.sh
================================================
#!/bin/bash

# build-install-dumb-init.sh
#
# Copyright (C) 2017-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

set -x

builddir=`mktemp -d` || exit 1
cd $builddir || exit 1

if grep -q Alma /etc/*release; then
    INSTALL_CMD="dnf -y install glibc-static"
    REMOVE_CMD="dnf -y remove glibc-static"
elif grep -q CentOS /etc/*release; then
    INSTALL_CMD="yum -y install glibc-static"
    REMOVE_CMD="yum -y remove glibc-static"
elif grep -q Fedora /etc/*release; then
    INSTALL_CMD="dnf -y install glibc-static"
    REMOVE_CMD="dnf -y remove glibc-static"
elif grep -q Ubuntu /etc/*release || grep -q Debian /etc/*release; then
    INSTALL_CMD=""
    REMOVE_CMD=""
elif grep -q openSUSE /etc/*release; then
    INSTALL_CMD="zypper --non-interactive install glibc-devel-static"
    REMOVE_CMD="zypper --non-interactive remove glibc-devel-static"
else
    exit 1
fi

wget https://github.com/Yelp/dumb-init/archive/v1.2.5.tar.gz || exit 1
echo "3eda470d8a4a89123f4516d26877a727c0945006c8830b7e3bad717a5f6efc4e  v1.2.5.tar.gz" > sha256sums || exit 1

sha256sum -c sha256sums || exit 1
tar xf v1.2.5.tar.gz || exit 1
# https://github.com/Yelp/dumb-init/issues/273
sed -i '128 i \ \ \ \ packages=[],' dumb-init*/setup.py || exit 1
# https://github.com/Yelp/dumb-init/issues/286
echo py >> dumb-init*/requirements-dev.txt

# Replace the versions of python used for testing dumb-init. Since it is
# testing c code, and not python it shouldn't matter. Also remove the
# pre-commit test from the test rule because we don't care.
sed -i -e 's/envlist = .*/envlist = py3/' dumb-init*/tox.ini || exit 1
sed -i -e 's/tox -e pre-commit//' dumb-init*/Makefile || exit 1

$INSTALL_CMD || exit 1

virtualenv $builddir/venv || exit 1
. $builddir/venv/bin/activate || exit 1
pip3 install setuptools tox || exit 1

. $builddir/venv/bin/activate || exit 1
cd dumb-init* || exit 1
make dumb-init || exit 1
make test || exit 1

cp dumb-init /usr/bin/dumb-init || exit 1
chmod +x /usr/bin/dumb-init || exit 1

rm $builddir -rf || exit 1
# Really this should be an exit 1 as well if it fails, but for some reason
# on travis, for fedora it consistently says that it cannot acquire the
# the transaction lock.
$REMOVE_CMD || exit 0


================================================
FILE: build_container.sh
================================================
#!/bin/bash

# build-container.sh
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

set -e

# Allow the user to specify another command to use for building such as podman
if [ "${ENGINE_CMD}" = "" ]; then
    ENGINE_CMD="docker"
fi

# DISTRO_TO_BUILD is essentially the prefix to the "base" and "builder"
# directories you plan to use. i.e. "fedora-23" or "ubuntu-16.04"

# First build the base
TAG=$DISTRO_TO_BUILD-base
dockerdir=`find -name $TAG`
workdir=`mktemp --tmpdir -d tmp-$TAG.XXX`

cp -r $dockerdir $workdir
workdir=$workdir/$TAG

cp build-install-dumb-init.sh $workdir
cp install-buildtools.sh $workdir
cp install-buildtools-make.sh $workdir
cd $workdir

baseimage=`grep FROM Dockerfile | sed -e 's/FROM //'`
${ENGINE_CMD} pull $baseimage

${ENGINE_CMD} build \
       --build-arg TARGETPLATFORM=$TARGETPLATFORM \
       --build-arg http_proxy=$http_proxy \
       --build-arg HTTP_PROXY=$http_proxy \
       --build-arg https_proxy=$https_proxy \
       --build-arg HTTPS_PROXY=$https_proxy \
       --build-arg no_proxy=$no_proxy \
       --build-arg NO_PROXY=$no_proxy \
       -t $REPO:$TAG .
rm $workdir -rf
cd -

# Now build the builder. We copy things to a temporary directory so that we
# can modify the Dockerfile to use whatever REPO is in the environment.
TAG=$DISTRO_TO_BUILD-builder
workdir=`mktemp --tmpdir -d tmp-$TAG.XXX`

# use the builder template to populate the distro specific Dockerfile
cp dockerfiles/templates/Dockerfile.builder $workdir/Dockerfile
cp distro-entry.sh $workdir
sed -i "s/DISTRO_TO_BUILD/$DISTRO_TO_BUILD/g" $workdir/Dockerfile

cp helpers/runbitbake.py $workdir
cd $workdir

# Replace the rewitt/yocto repo with the one from environment
sed -i -e "s#crops/yocto#$REPO#" Dockerfile

# Lastly build the image
${ENGINE_CMD} build \
       --build-arg TARGETPLATFORM=$TARGETPLATFORM \
       --build-arg http_proxy=$http_proxy \
       --build-arg HTTP_PROXY=$http_proxy \
       --build-arg https_proxy=$https_proxy \
       --build-arg HTTPS_PROXY=$https_proxy \
       --build-arg no_proxy=$no_proxy \
       --build-arg NO_PROXY=$no_proxy \
       -t $REPO:$TAG .
cd -

# base tests
ENGINE_CMD=${ENGINE_CMD} \
    ./tests/container/vnc-test.sh $REPO:$DISTRO_TO_BUILD-base
# builder tests
ENGINE_CMD=${ENGINE_CMD} \
    ./tests/container/smoke.sh $REPO:$DISTRO_TO_BUILD-builder

rm $workdir -rf


================================================
FILE: buildall.sh
================================================
#!/bin/bash

# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

PIDS=()
# some systems do not have enough tty's available to run all the
# dumbinit tests in parallel. If the tty tests are failing try
# setting SERIAL_BUILD=1
if [ "$SERIAL_BUILD" == "" ]; then
    SERIAL_BUILD=0
fi
trap cleanup SIGINT SIGTERM ERR
function cleanup () {
    # Since we're calling kill again on the entire process group make sure
    # to not recurse into cleanup() by disabling the trap on SIGTERM.
    trap - SIGTERM
    kill -- -$$

    exit 1
}

build_image() {
    OUTPUTDIR=$1
    REPO=$2
    DISTRO_TO_BUILD=$3
    TMPDIR=$OUTPUTDIR REPO=$REPO \
        DISTRO_TO_BUILD=$DISTRO_TO_BUILD \
        bash -c "$build_cont . >& \
                    $OUTPUTDIR/build.log || \
                    echo \"$DISTRO_TO_BUILD build failed\""
}

function build_images {
    PIDS=()
    localrepo=$2
    tmpdir=$(mktemp --tmpdir -d tmp-buildall.XXX)

    echo "Building REPO=$REPO in $tmpdir"

    for i in $1; do
        DISTRO_TO_BUILD=$(basename $i)
        OUTPUTDIR=$tmpdir/$DISTRO_TO_BUILD
        mkdir $OUTPUTDIR

        echo "Building $DISTRO_TO_BUILD"

        if [ $SERIAL_BUILD == "0" ]; then
            build_image $OUTPUTDIR $REPO $DISTRO_TO_BUILD &
        else
            build_image $OUTPUTDIR $REPO $DISTRO_TO_BUILD
        fi
        PIDS=( ${PIDS[@]} $! )
    done
}

function waitforimages {
    numpids=${#PIDS[@]}
    while [ $numpids -gt 0 ]; do
        echo "waiting for $numpids images to be built"
        wait -n
        if [ $? -ne 0 ]; then
            cleanup
        fi
        numpids=$((numpids-1))
    done
}


set -e

SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
cd $SCRIPTDIR

if [ "x" = "x$REPO" ]; then
    # Create a uid for the repo so we don't overwrite any user images
    REPO=$(uuidgen)-yocto-docker-test
fi

build_cont=`readlink -f ./build_container.sh`

DIRS=$(readlink -f $(dirname $(dirname $(find -path '*base/Dockerfile'))))
build_images "$DIRS"
waitforimages


================================================
FILE: deploy.sh
================================================
#!/bin/bash
# Copyright (C) 2016-2021 Intel Corporation
# Copyright (C) 2022 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#
# This script is meant to be consumed by travis. It's very simple but running
# a loop in travis.yml isn't a great thing.
set -e

# Allow the user to specify another command to use for building such as podman
if [ "${ENGINE_CMD}" = "" ]; then
    ENGINE_CMD="docker"
fi

# Don't deploy on pull requests because it could just be junk code that won't
# get merged
if ([ "${GITHUB_EVENT_NAME}" = "push" ] || [ "${GITHUB_EVENT_NAME}" = "workflow_dispatch" ] || [ "${GITHUB_EVENT_NAME}"  = "schedule" ])  && [ "${GITHUB_REF}" = "refs/heads/master" ]; then
    echo $DOCKER_PASSWORD | ${ENGINE_CMD} login -u $DOCKER_USERNAME --password-stdin
    ${ENGINE_CMD} push $REPO:$DISTRO_TO_BUILD-base
    ${ENGINE_CMD} push $REPO:$DISTRO_TO_BUILD-builder

    ${ENGINE_CMD} tag $REPO:$DISTRO_TO_BUILD-base ghcr.io/$REPO:$DISTRO_TO_BUILD-base
    ${ENGINE_CMD} tag $REPO:$DISTRO_TO_BUILD-builder ghcr.io/$REPO:$DISTRO_TO_BUILD-builder

    echo $GHCR_PASSWORD | ${ENGINE_CMD} login ghcr.io -u $GHCR_USERNAME --password-stdin
    ${ENGINE_CMD} push ghcr.io/$REPO:$DISTRO_TO_BUILD-base
    ${ENGINE_CMD} push ghcr.io/$REPO:$DISTRO_TO_BUILD-builder
fi


================================================
FILE: distro-entry.sh
================================================
#!/bin/bash
# Copyright (C) 2019-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

RELEASE="4.1"

if [ "$(uname -m)" = "aarch64" ]; then
    SETUPSCRIPT="environment-setup-aarch64-pokysdk-linux"
elif [ "$(uname -m)" = "x86_64" ]; then
    SETUPSCRIPT="environment-setup-x86_64-pokysdk-linux"
fi

# This entry point is so that we can do distro specific changes to the launch.
if [ -e /opt/poky/${RELEASE}/${SETUPSCRIPT} ]; then
    # Buildtools has been installed so enable it
    . /opt/poky/${RELEASE}/${SETUPSCRIPT} || exit 1
elif [ -e /opt/poky/${RELEASE}/${SETUPSCRIPT} ]; then
    # Buildtools(-make) has been installed so enable it
    . /opt/poky/${RELEASE}/${SETUPSCRIPT} || exit 1
fi

exec "$@"


================================================
FILE: dockerfiles/alma/alma-8/alma-8-base/Dockerfile
================================================
# alama-8-base
# Copyright (C) 2015-2020 Intel Corporation
# Copyright (C) 2022 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM almalinux:8

RUN dnf install -y 'dnf-command(config-manager)' && \
    dnf config-manager --set-enabled powertools && \
    dnf -y install epel-release && \
    dnf -y update && \
    dnf -y install \
        bzip2 \
        ccache \
        chrpath \
        cpio \
        cpp \
        diffstat \
        diffutils \
        file \
        gawk \
        gcc \
        gcc-c++ \
        git \
        glibc-devel \
        glibc-langpack-en \
        gzip \
        lz4 \
        make \
        patch \
        perl \
        perl-Data-Dumper \
        perl-Text-ParseWords \
        perl-Thread-Queue \
        procps \
        python3 \
        python3-GitPython \
        python3-jinja2 \
        python3-pexpect \
        python3-pip \
        python3-virtualenv \
        rpcgen \
        socat \
        subversion \
        sudo \
        tar \
        texinfo \
        tigervnc-server \
        tmux \
        unzip \
        wget \
        which \
        xz \
        zstd && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    groupadd -g 1000 yoctouser && \
    useradd -u 1000 -g yoctouser -m yoctouser

# Install buildtools. The original reason this was needed was due to a
# sanity check for make 4.1.2, but now we're relying on python-3.8 so instead
# of -make, install all the buildtools

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     dnf -y clean all

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/alma/alma-9/alma-9-base/Dockerfile
================================================
# alama-9-base
# Copyright (C) 2015-2020 Intel Corporation
# Copyright (C) 2022 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM almalinux:9

RUN dnf install -y 'dnf-command(config-manager)' && \
    dnf config-manager --set-enabled crb && \
    dnf -y install epel-release && \
    dnf -y update && \
    dnf -y install \
        bzip2 \
        ccache \
        chrpath \
        cpio \
        cpp \
        diffstat \
        diffutils \
        file \
        gawk \
        gcc \
        gcc-c++ \
        git \
        glibc-devel \
        glibc-langpack-en \
        gzip \
        lz4 \
        make \
        patch \
        perl \
        perl-Data-Dumper \
        perl-Text-ParseWords \
        perl-Thread-Queue \
        procps \
        python3 \
        python3-GitPython \
        python3-jinja2 \
        python3-pexpect \
        python3-pip \
        python3-virtualenv \
        rpcgen \
        socat \
        subversion \
        sudo \
        tar \
        texinfo \
        tigervnc-server \
        tmux \
        unzip \
        wget \
        which \
        xz \
        zstd && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    groupadd -g 1000 yoctouser && \
    useradd -u 1000 -g yoctouser -m yoctouser

# Install buildtools-make. The original reason this was needed was due to a
# sanity check for make 4.1.2
COPY install-buildtools-make.sh /
RUN bash /install-buildtools-make.sh && \
    rm /install-buildtools-make.sh

COPY build-install-dumb-init.sh /
RUN  bash build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     dnf -y clean all

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/debian/debian-10/debian-10-base/Dockerfile
================================================
# debian-10-base
# Copyright (C) 2015-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM debian:10

ARG TARGETPLATFORM

RUN apt-get clean && \
    apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        build-essential \
        chrpath \
        cpio \
        diffstat \
        fluxbox \
        gawk \
        git-core \
        locales \
        lz4 \
        procps \
        python \
        python-virtualenv \
        python3 \
        python3-pip \
        python3-virtualenv \
        screen \
        socat \
        subversion \
        sudo \
        sysstat \
        texinfo \
        tightvncserver \
        tmux \
        unzip \
        wget \
        xz-utils \
        zstd && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen && locale-gen

# Install buildtools. The original reason this was needed was due to a
# sanity check for make 4.1.2, but now we're relying on python-3.8 so instead
# of -make, install all the buildtools

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/debian/debian-11/debian-11-base/Dockerfile
================================================
# debian-11-base
# Copyright (C) 2015-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM debian:11

ARG TARGETPLATFORM

RUN apt-get clean && \
    apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        build-essential \
        chrpath \
        cpio \
        diffstat \
        fluxbox \
        gawk \
        git-core \
        locales \
        lz4 \
        procps \
        python \
        python3 \
        python3-pip \
        python3-virtualenv \
        screen \
        socat \
        subversion \
        sudo \
        sysstat \
        texinfo \
        tightvncserver \
        tmux \
        unzip \
        wget \
        xz-utils \
        zstd && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen && locale-gen

COPY build-install-dumb-init.sh  /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/debian/debian-12/debian-12-base/Dockerfile
================================================
# debian-12-base
# Copyright (C) 2015-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM debian:12

ARG TARGETPLATFORM

RUN apt-get clean && \
    apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        build-essential \
        chrpath \
        cpio \
        diffstat \
        file \
        fluxbox \
        gawk \
        git-core \
        locales \
        lz4 \
        procps \
        python3 \
        python3-pip \
        python3-virtualenv \
        screen \
        socat \
        subversion \
        sudo \
        sysstat \
        texinfo \
        tightvncserver \
        tmux \
        unzip \
        wget \
        xz-utils \
        zstd && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    echo 'en_US.UTF-8 UTF-8' >> /etc/locale.gen && locale-gen

COPY build-install-dumb-init.sh  /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/fedora/fedora-39/fedora-39-base/Dockerfile
================================================
# fedora-39-base
# Copyright (C) 2021 Intel Corporation
# Copyright (C) 2021-2024 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM fedora:39

RUN dnf -y update && \
    dnf -y install \
	# These packages were copied straight from the Yocto Project reference
        # manual which is why they are not alphabetized
        gawk \
        make \
        wget \
        tar \
        bzip2 \
        gzip \
        python3 \
        unzip \
        perl \
        patch \
        diffutils \
        diffstat \
        git \
        cpp \
        gcc \
        gcc-c++ \
        glibc-devel \
        texinfo \
        chrpath \
        ccache \
        perl-Data-Dumper \
        perl-Text-ParseWords \
        perl-Thread-Queue \
        perl-bignum \
        socat \
        python3-pexpect \
        findutils \
        which \
        file \
        cpio \
        python3-pip \
        xz \
        python3-GitPython \
        python3-jinja2 \
        python3-virtualenv \
        SDL-devel \
        xterm \
        rpcgen \
	lz4 \
	zstd \
        \
        # These packages were added because of reasons such as fewer packages
        # being in the container image by default
        fluxbox \
        glibc-langpack-en \
        hostname \
        procps \
        python-unversioned-command \
        subversion \
        sudo \
        screen \
        tigervnc-server \
        tmux && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     dnf -y clean all

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/fedora/fedora-40/fedora-40-base/Dockerfile
================================================
# fedora-40-base
# Copyright (C) 2021 Intel Corporation
# Copyright (C) 2021-2024 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM fedora:40

RUN dnf -y update && \
    dnf -y install \
	# These packages were copied straight from the Yocto Project reference
        # manual which is why they are not alphabetized
        gawk \
        make \
        wget \
        tar \
        bzip2 \
        gzip \
        python3 \
        unzip \
        perl \
        patch \
        diffutils \
        diffstat \
        git \
        cpp \
        gcc \
        gcc-c++ \
        glibc-devel \
        texinfo \
        chrpath \
        ccache \
        perl-Data-Dumper \
        perl-Text-ParseWords \
        perl-Thread-Queue \
        perl-bignum \
        socat \
        python3-pexpect \
        findutils \
        which \
        file \
        cpio \
        python3-pip \
        xz \
        python3-GitPython \
        python3-jinja2 \
        python3-virtualenv \
        SDL-devel \
        xterm \
        rpcgen \
	lz4 \
	zstd \
        \
        # These packages were added because of reasons such as fewer packages
        # being in the container image by default
        fluxbox \
        glibc-langpack-en \
        hostname \
        procps \
        python-unversioned-command \
        subversion \
        sudo \
        screen \
        tigervnc-server \
        tmux && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser

# Install buildtools for wget

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     dnf -y clean all

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/opensuse/opensuse-15.4/opensuse-15.4-base/Dockerfile
================================================
# opensuse-15.4-base
# Copyright (C) 2015-2020 Intel Corporation
# Copyright (C) 2022 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
##

FROM opensuse/leap:15.4

# Keep these in alphabetical order, as sorted by vim :sort
RUN zypper --non-interactive install \
                   bzip2 \
                   chrpath \
                   diffstat \
                   gcc \
                   gcc-c++ \
                   git \
                   glibc-locale \
                   gzip \
                   iproute2 \
                   libSDL-devel \
                   lz4 \
                   make \
                   makeinfo \
                   net-tools \
                   patch \
                   python \
                   python-curses \
                   python-xml \
                   python3 \
		   python3-Jinja2 \
                   python3-curses \
		   python3-pexpect \
		   python3-pip \
                   python3-virtualenv \
                   rpcgen \
                   socat \
                   subversion \
                   sudo \
                   tar \
                   wget \
                   xorg-x11-Xvnc \
                   xz \
                   zstd && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser

# Install buildtools. The original reason this was needed was due to a
# sanity check for make 4.1.2, but now we're relying on python-3.8 so instead
# of -make, install all the buildtools

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/opensuse/opensuse-15.5/opensuse-15.5-base/Dockerfile
================================================
# opensuse-15.5-base
# Copyright (C) 2015-2020 Intel Corporation
# Copyright (C) 2022-2024 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
##

FROM opensuse/leap:15.5

# Keep these in alphabetical order, as sorted by vim :sort
RUN zypper --non-interactive install \
                   bzip2 \
                   chrpath \
                   diffstat \
                   gcc \
                   gcc-c++ \
                   git \
                   glibc-locale \
                   gzip \
                   iproute2 \
                   libSDL-devel \
                   lz4 \
                   make \
                   makeinfo \
                   net-tools \
                   patch \
                   python3 \
                   python3-Jinja2 \
                   python3-curses \
                   python3-pexpect \
                   python3-pip \
                   python3-virtualenv \
                   rpcgen \
                   socat \
                   subversion \
                   sudo \
                   tar \
                   wget \
                   xorg-x11-Xvnc \
                   xz \
                   zstd && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser

# Install buildtools. The original reason this was needed was due to a
# sanity check for make 4.1.2, but now we're relying on python-3.8 so instead
# of -make, install all the buildtools

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/opensuse/opensuse-15.6/opensuse-15.6-base/Dockerfile
================================================
# opensuse-15.6-base
# Copyright (C) 2015-2020 Intel Corporation
# Copyright (C) 2022-2024 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
##

FROM opensuse/leap:15.6

# Keep these in alphabetical order, as sorted by vim :sort
RUN zypper --non-interactive install \
                   bzip2 \
                   chrpath \
                   diffstat \
                   gcc \
                   gcc-c++ \
                   git \
                   glibc-locale \
                   gzip \
                   hostname \
                   iproute2 \
                   libacl1 \
                   lz4 \
                   make \
                   makeinfo \
                   net-tools \
                   patch \
                   python3 \
                   python3-Jinja2 \
                   python3-curses \
                   python3-pexpect \
                   python3-pip \
                   python3-virtualenv \
                   rpcgen \
                   socat \
                   subversion \
                   sudo \
                   tar \
                   wget \
                   xorg-x11-Xvnc \
                   xz \
                   zstd && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser

# Install buildtools. The original reason this was needed was due to a
# sanity check for make 4.1.2, but now we're relying on python-3.8 so instead
# of -make, install all the buildtools

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/templates/Dockerfile.builder
================================================
# DISTRO_TO_BUILD-builder
# Copyright (C) 2015-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM crops/yocto:DISTRO_TO_BUILD-base

USER root
COPY distro-entry.sh runbitbake.py /usr/local/bin/
RUN chown  yoctouser:yoctouser /usr/local/bin/runbitbake.py && \
    chmod +x /usr/local/bin/runbitbake.py && \
    chmod +x /usr/local/bin/distro-entry.sh

USER yoctouser

WORKDIR /home/yoctouser
ENTRYPOINT ["/usr/local/bin/distro-entry.sh", "/usr/local/bin/runbitbake.py"]


================================================
FILE: dockerfiles/ubuntu/ubuntu-18.04/ubuntu-18.04-base/Dockerfile
================================================
# ubuntu-18.04-base
# Copyright (C) 2015-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM ubuntu:18.04

ARG TARGETPLATFORM

RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        gawk \
        wget \
        git-core \
        subversion \
        diffstat \
        unzip \
        sysstat \
        texinfo \
        build-essential \
        chrpath \
        socat \
        python \
        python-virtualenv \
        python3 \
	python3-pip \
        python3-virtualenv \
        xz-utils  \
        locales \
        cpio \
        screen \
        tmux \
        sudo \
        iputils-ping \
        iproute2 \
        fluxbox \
        tightvncserver \
        liblz4-tool \
        zstd && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    /usr/sbin/locale-gen en_US.UTF-8 && \
    echo 'dash dash/sh boolean false' | debconf-set-selections && \
    DEBIAN_FRONTEND=noninteractive dpkg-reconfigure dash

# Install buildtools due to python 3.8

COPY install-buildtools.sh /
RUN bash /install-buildtools.sh && \
    rm /install-buildtools.sh

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/ubuntu/ubuntu-20.04/ubuntu-20.04-base/Dockerfile
================================================
# ubuntu-20.04-base
# Copyright (C) 2020-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM ubuntu:20.04

ARG TARGETPLATFORM

RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        gawk \
        wget \
        git-core \
        subversion \
        diffstat \
        unzip \
        sysstat \
        texinfo \
        build-essential \
        chrpath \
        socat \
        python \
        python3 \
        python3-pip \
        python3-pexpect \
        xz-utils  \
        locales \
        cpio \
        screen \
        tmux \
        sudo \
        iputils-ping \
        python3-git \
        python3-jinja2 \
        python3-virtualenv \
        libegl1-mesa \
        libsdl1.2-dev \
        pylint3 \
        xterm \
        iproute2 \
        fluxbox \
        tightvncserver \
        lz4 \
        zstd && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    /usr/sbin/locale-gen en_US.UTF-8 && \
    echo 'dash dash/sh boolean false' | debconf-set-selections && \
    DEBIAN_FRONTEND=noninteractive dpkg-reconfigure dash

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/ubuntu/ubuntu-22.04/ubuntu-22.04-base/Dockerfile
================================================
# ubuntu-22.04-base
# Copyright (C) 2020-2021 Intel Corporation
# Copyright (C) 2022 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM ubuntu:22.04

ARG TARGETPLATFORM

RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        gawk \
        wget \
        git-core \
        subversion \
        diffstat \
        unzip \
        sysstat \
        texinfo \
        build-essential \
        chrpath \
        socat \
        python3 \
        python3-pip \
        python3-pexpect \
        python3-virtualenv \
        xz-utils  \
        locales \
        cpio \
        screen \
        tmux \
        sudo \
        iputils-ping \
        python3-git \
        python3-jinja2 \
        libegl1-mesa \
        libsdl1.2-dev \
        pylint \
        xterm \
        iproute2 \
        fluxbox \
        tightvncserver \
        lz4 \
        zstd \
        file && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    /usr/sbin/locale-gen en_US.UTF-8 && \
    echo 'dash dash/sh boolean false' | debconf-set-selections && \
    DEBIAN_FRONTEND=noninteractive dpkg-reconfigure dash

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: dockerfiles/ubuntu/ubuntu-24.04/ubuntu-24.04-base/Dockerfile
================================================
# ubuntu-24.04-base
# Copyright (C) 2020-2021 Intel Corporation
# Copyright (C) 2022-2024 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#

FROM ubuntu:24.04

ARG TARGETPLATFORM

RUN apt-get update && \
    DEBIAN_FRONTEND=noninteractive apt-get install -y \
        gawk \
        wget \
        git-core \
        subversion \
        diffstat \
        unzip \
        sysstat \
        texinfo \
        build-essential \
        chrpath \
        socat \
        python3 \
        python3-pip \
        python3-pexpect \
        python3-virtualenv \
        xz-utils  \
        locales \
        cpio \
        screen \
        tmux \
        sudo \
        iputils-ping \
        python3-git \
        python3-jinja2 \
        pylint \
        xterm \
        iproute2 \
        fluxbox \
        tightvncserver \
        lz4 \
        zstd \
        file && \
    case ${TARGETPLATFORM} in \
        "linux/amd64") \
            DEBIAN_FRONTEND=noninteractive apt-get install -y \
                gcc-multilib \
                g++-multilib \
            ;; \
    esac && \
    cp -af /etc/skel/ /etc/vncskel/ && \
    echo "export DISPLAY=1" >>/etc/vncskel/.bashrc && \
    mkdir  /etc/vncskel/.vnc && \
    echo "" | vncpasswd -f > /etc/vncskel/.vnc/passwd && \
    chmod 0600 /etc/vncskel/.vnc/passwd && \
    useradd -U -m yoctouser && \
    /usr/sbin/locale-gen en_US.UTF-8 && \
    echo 'dash dash/sh boolean false' | debconf-set-selections && \
    DEBIAN_FRONTEND=noninteractive dpkg-reconfigure dash

COPY build-install-dumb-init.sh /
RUN  bash /build-install-dumb-init.sh && \
     rm /build-install-dumb-init.sh && \
     apt-get clean

USER yoctouser
WORKDIR /home/yoctouser
CMD /bin/bash


================================================
FILE: helpers/runbitbake.py
================================================
#!/usr/bin/env python3

# runbitbake.py
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

import argparse
import subprocess
import os
import tempfile
import shutil
import sys
import signal

bitbake_process = None

old_handler = {}
old_handler[str(signal.SIGINT)] = signal.getsignal(signal.SIGINT)
old_handler[str(signal.SIGTERM)] = signal.getsignal(signal.SIGTERM)


def addextra(tempdir, builddir, name, extralist):
    # If there is no extraconf there, is no reason to do any other work
    if extralist is None:
        return

    myf = "{}/conf/{}".format(builddir, name)
    myf_orig = "{}/{}.orig".format(tempdir, name)
    tmpfile = "{}/{}.orig.tmp".format(tempdir, name)

    # copy isn't atomic so make sure that orig is created atomically so that
    # file.orig is always correct even if file gets hosed. So that
    # means if a user ever sees file.orig, they can be assured that it
    # is the same as the original file with no corruption.
    shutil.copyfile(myf, tmpfile)
    with open(tmpfile, "r") as f:
        fd = f.fileno()
        os.fdatasync(fd)

    # Remember first sync the file AND directory to make sure data
    # is written out
    fd = os.open(os.path.dirname(tmpfile), os.O_RDONLY)
    os.fsync(fd)
    os.close(fd)

    # Rename should be atomic with respect to disk, yes all of this assumes
    # linux and possibly non-network filesystems.
    os.rename(tmpfile, myf_orig)

    with open(myf, "a") as f:
        if extralist:
            for conf in extralist:
                with open(conf) as f2:
                    content = f2.readlines()
                for l in content:
                    f.write("%s\n" % format(l.strip()))


def restore_files(tempdir, builddir, conffiles):
    for f in conffiles:
        dest = os.path.join(builddir, "conf", f)
        src = os.path.join(tempdir, f + ".orig")

        if os.path.exists(src):
            os.rename(src, dest)


# If bitbake is around let it do all the signal handling
def handler(signum, frame):
    if bitbake_process:
        # SIGINT is special if there is a tty. Because with a tty SIGINT will
        # automatically get sent to all processes in the process group. So we
        # don't need to send it ourselves.
        if signum == signal.SIGINT and sys.stdin.isatty():
            pass
        else:
            # If there is a bitbake process we want to let it tear down all
            # its children itself so send the signal to bitbake.
            bitbake_process.send_signal(signum)
    else:
        old_handler[str(signum)](signum, frame)


if __name__ == '__main__':
    signal.signal(signal.SIGINT, handler)
    signal.signal(signal.SIGTERM, handler)

    parser = argparse.ArgumentParser()

    parser.add_argument("--extraconf", action='append', help="File containing"
                        "extra configuration")
    parser.add_argument("--extralayers", action='append',
                        help="File containing extra bblayers")

    parser.add_argument("--pokydir", default="/home/yoctouser/poky",
                        required=True, help="Directory containing poky")
    parser.add_argument("--target", "-t", required=True,
                        help="What bitbake should build")
    parser.add_argument("--builddir", "-b", required=True,
                        help="Directory to build in")

    args = parser.parse_args()

    builddir = args.builddir

    if not os.path.isdir(builddir):
        os.makedirs(builddir)

    # tempdir is a subdirectory of builddir in case builddir and local.conf
    # already existed. Then if something goes wrong with local.conf the user
    # can restore it by using builddir/tempdir/local.conf.orig
    tempdir = tempfile.mkdtemp(prefix="runbitbake-tmpdir", dir=builddir)

    # Have to use bash since the default on ubuntu is dash which won't work
    try:
        cmd = 'bash -c ". {}/oe-init-build-env {}"'.format(args.pokydir,
                                                           builddir)
        subprocess.check_call(cmd, stdout=sys.stdout, stderr=sys.stderr,
                              shell=True)

        try:
            addextra(tempdir, builddir, "local.conf", args.extraconf)
            addextra(tempdir, builddir, "bblayers.conf", args.extralayers)

            cmd = 'export LANG=en_US.UTF-8 && '
            cmd += '. {}/oe-init-build-env {} && '.format(args.pokydir,
                                                          builddir)
            cmd += 'exec bitbake {}'.format(args.target)
            bitbake_process = subprocess.Popen(['/bin/bash', '-c', cmd],
                                               stdout=sys.stdout,
                                               stderr=sys.stderr, shell=False)

            bitbake_process.wait()

            if bitbake_process.returncode != 0:
                raise subprocess.CalledProcessError(bitbake_process.returncode,
                                                    cmd)
        finally:
            restore_files(tempdir, builddir, ["local.conf", "bblayers.conf"])

    except subprocess.CalledProcessError as e:
        print(e)
        sys.exit(1)

    finally:
        shutil.rmtree(tempdir, ignore_errors=True)


================================================
FILE: install-buildtools-make.sh
================================================
#! /bin/bash

# install-buildtools-make.sh
#
# Copyright (C) 2020-2021 Intel Corporation
# Copyright (C) 2022 Konsulko Group
#
# SPDX-License-Identifier: GPL-2.0-only
#
set -e

RELEASE="4.1"
if [ "$(uname -m)" = "aarch64" ]; then
    BUILDTOOLS="aarch64-buildtools-make-nativesdk-standalone-${RELEASE}.sh"
    SHA256SUM="ed241869743ac795d1a988246953df5931f68c22108d6f86ebc485b773d28db4"
elif [ "$(uname -m)" = "x86_64" ]; then
    BUILDTOOLS="x86_64-buildtools-make-nativesdk-standalone-${RELEASE}.sh"
    SHA256SUM="d9cc8a4f76392e23f9b2854af78d460e99bb5e4cbb82de6ccca0f6be7506f652"
else
    echo "Unsupported architecture, can't install buildtools-make."
    exit 1
fi

wget https://downloads.yoctoproject.org/releases/yocto/yocto-${RELEASE}/buildtools/${BUILDTOOLS}

echo "${SHA256SUM} ${BUILDTOOLS}" > SHA256SUMS
sha256sum -c SHA256SUMS
rm SHA256SUMS

bash ${BUILDTOOLS} -y
rm ${BUILDTOOLS}


================================================
FILE: install-buildtools.sh
================================================
#! /bin/bash

# install-buildtools.sh
#
# Copyright (C) 2020-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#
set -e

RELEASE="4.1"
if [ "$(uname -m)" = "aarch64" ]; then
    BUILDTOOLS="aarch64-buildtools-extended-nativesdk-standalone-${RELEASE}.sh"
    SHA256SUM="d5c0dd3e43c62f0465a9335f450d9f5f6861e4b3d39b0f04174bd50e6861c96e"
elif [ "$(uname -m)" = "x86_64" ]; then
    BUILDTOOLS="x86_64-buildtools-extended-nativesdk-standalone-${RELEASE}.sh"
    SHA256SUM="d360ac01016c848f713d6dd7848f25d0a5319e96e2dd279ab37ffcbd7320dbbe"
else
    echo "Unsupported architecture, can't install buildtools-make."
    exit 1
fi

wget https://downloads.yoctoproject.org/releases/yocto/yocto-${RELEASE}/buildtools/${BUILDTOOLS}

echo "${SHA256SUM} ${BUILDTOOLS}" > SHA256SUMS
sha256sum -c SHA256SUMS
rm SHA256SUMS

bash ${BUILDTOOLS} -y
rm ${BUILDTOOLS}


================================================
FILE: tests/container/smoke.sh
================================================
#!/bin/bash

# smoke.sh
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

set -e
set -x

echo $USER
id

if [ "${ENGINE_CMD}" = "" ]; then
    ENGINE_CMD="docker"
fi

# Pass in the image that was built for docker
image=$1
workdir=`mktemp -d --suffix=smoke`
pokydir=/workdir/poky
builddir=/workdir/build

# This is to guarantee yoctouser in the container has access to workdir
chmod -R 777 $workdir

# In each instance below where docker is started, the workdir is changed to one
# that should be accessible for the uid:gid specified. Otherwise starting the
# container may fail.

# Ensure dumb-init is installed. This is to try and catch if
# build-install-dumb-init.sh didn't work.
${ENGINE_CMD} run -t --rm --entrypoint=/bin/bash -u $(id -u):$(id -g) -w '/' $image -c 'ls /usr/bin/dumb-init'

# Try to build quilt-native which is small and fast to build.
git clone --depth 1 --branch master \
          git://git.yoctoproject.org/poky $workdir/poky
${ENGINE_CMD} run -t --rm -v $workdir:/workdir -u $(id -u):$(id -g) -w '/' $image --pokydir=$pokydir \
                  -b $builddir -t quilt-native

# Since yoctouser in the container may create files that the travis user
# can't delete, run the container again to delete the files in the directory.
${ENGINE_CMD} run -t --rm -v $workdir:/workdir -u $(id -u):$(id -g) -w '/' --entrypoint=/bin/rm $image \
                  $builddir -rf

rm $workdir -rf


================================================
FILE: tests/container/vnc-in-container-test.sh
================================================
#!/bin/bash

# vnc-in-container.sh
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

set -e
set -x
# this runs inside the container. Returns 0 on success.
ls -al /workdir
# make a vncuser from the skeleton
useradd -m --skel=/etc/vncskel vncuser

# install xdpyinfo in the distros that are missing it
if grep -q Alma /etc/*release; then
    dnf -y install xorg-x11-utils
elif grep -q CentOS /etc/*release; then
    yum -y install xorg-x11-utils
# since fedora-34, xdpyinfo is its own package
# since fedora-35, xorg-x11-utils has been dropped
elif grep -q Fedora /etc/*release; then
    dnf -y install xdpyinfo
elif grep -q Ubuntu /etc/*release || grep -q Debian /etc/*release; then
    # Ubuntu/debian brings in xdpyinfo by default
    true;
elif grep -q openSUSE /etc/*release; then
    zypper --non-interactive install xdpyinfo
else
    exit 1
fi

###
### This runs each of the following commands as the user
### vncuser.  Note, variables from 1 line will not be available
### for the next.
###
exec sudo -H -u vncuser /bin/bash - <<EOF

# start the server
Xvnc -rfbport 5900 :1 >& /home/vncuser/.vnc/Xvnc.log &
sleep 2

if grep Listening  /home/vncuser/.vnc/*.log | grep 5900 ; then
echo "port established"
else
echo "port NOT established"
exit 1
fi
DISPLAY=:1 xdpyinfo | grep "number of screens"
if DISPLAY=:1 xdpyinfo | egrep -q "number of screens" ; then
echo "xdpyinfo shows screens established";
else
echo "xdpyinfo shows screens NOT established";
exit 1
fi
if grep DISPLAY /home/vncuser/.bashrc; then
echo "DISPLAY set in bashrc"
else
echo "DISPLAY NOT set in bashrc"
exit 1
fi
EOF


================================================
FILE: tests/container/vnc-test.sh
================================================
#!/bin/bash

# vnc-test.sh
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

set -e
set -x

if [ "${ENGINE_CMD}" = "" ]; then
    ENGINE_CMD="docker"
fi

# Pass in the image that was built for docker
image=$1
workdir=`mktemp -d --suffix=vnc`
SCRIPT_DIR=$(dirname $(readlink -f $0))
CONTAINER_SCRIPT=vnc-in-container-test.sh
cp $SCRIPT_DIR/$CONTAINER_SCRIPT $workdir

${ENGINE_CMD} run -t --rm -v $workdir:/workdir \
    --entrypoint=/workdir/$CONTAINER_SCRIPT --user=root  $image
rm $workdir -rf


================================================
FILE: tests/unit/signals/bitbake
================================================
#!/usr/bin/env python3

# bitbake.py
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#
# This is for testing the signal forwarding of run_bitbake. It just waits for
# a signal and then outputs a message telling what signal it received.

import os
import signal
import sys
import time

def handler(signum, frame):
    print('Handler called with signal {}'.format(signum))
    sys.stdout.flush()
    sys.exit(0)

# Set the signal handler
signal.signal(signal.SIGTERM, handler)
signal.signal(signal.SIGINT, handler)

print('Waiting for signal')
sys.stdout.flush()
time.sleep(10)
sys.exit(1)


================================================
FILE: tests/unit/test_runbitbake.py
================================================
#!/usr/bin/env python3
#
# Copyright (C) 2016-2021 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-only
#

import unittest
import os
import subprocess
import shutil
import tempfile
import sys
import stat
import imp
import shlex
import signal
import pytest


class RunBitbakeTestBase(unittest.TestCase):
    def setUp(self):
        self.tempdir = tempfile.mkdtemp(prefix="runbitbaketest-tmpdir")

        self.pokydir = os.path.join(self.tempdir, "poky")
        os.mkdir(self.pokydir)

        # runbitbake.py requires --pokydir with a "oe-init-build-env" script
        self.setupscript = os.path.join(self.pokydir, "oe-init-build-env")
        with open(self.setupscript, "w"):
            pass

        # Create a builddir and confdir as if oe-init-build-env had ran
        self.builddir = os.path.join(self.tempdir, "build")
        self.confdir = os.path.join(self.builddir, "conf")
        os.mkdir(self.builddir)
        os.mkdir(self.confdir)

        # Create an executable bitbake that does nothing
        self.bindir = os.path.join(self.tempdir, "bin")
        os.mkdir(self.bindir)

        self.bitbake = os.path.join(self.bindir, "bitbake")
        with open(self.bitbake, "w") as f:
            f.write("#!/bin/sh\n")
            os.chmod(self.bitbake, stat.S_IRWXU)

        # Make sure runbitbake.py can run our fake bitbake
        os.environ["PATH"] = "{}:{}".format(self.bindir, os.environ["PATH"])

        # We will have one line local.conf and bblayers.conf.
        self.local_conf = os.path.join(self.confdir, "local.conf")
        with open(self.local_conf, "w") as f:
            f.write("Some data\n")

        self.bblayers_conf = os.path.join(self.confdir, "bblayers.conf")
        with open(self.bblayers_conf, "w") as f:
            f.write("Other data\n")

        # Create the files that contain extra data to be added to the original
        # configuration files
        self.extraconf = os.path.join(self.tempdir, "extra.conf")
        with open(self.extraconf, "w") as f:
            f.write("MOAR STUFF\nEVEN MOAR!!!!\n")

        self.extralayers = os.path.join(self.tempdir, "bblayers_extra.conf")
        with open(self.extralayers, "w") as f:
            f.write("BBLAYERS MOAR STUFF\nEVEN MOAR BBLAYERS!!!!\n")

    def tearDown(self):
        shutil.rmtree(self.tempdir, ignore_errors=True)


class ExitCodeTest(RunBitbakeTestBase):
    def setUp(self):
        super(ExitCodeTest, self).setUp()

        # Remove the bindir from the path so we know bitbake will fail
        self.pathorig = os.environ['PATH']
        os.environ['PATH'] = self.pathorig.split(':', 1)[1]

    def tearDown(self):
        os.environ['PATH'] = self.pathorig

    # Make sure the exitcode is nonzero if runbitbake fails
    def test_exit_code_non_zero(self):
        cmd = """python helpers/runbitbake.py --pokydir={} """ \
              """-t junk -b {} """.format(self.pokydir, self.builddir)
        rc = subprocess.call(cmd.split(), shell=False)
        self.assertNotEqual(0, rc)


class ConfFilesTest(RunBitbakeTestBase):
    def setUp(self):
        super(ConfFilesTest, self).setUp()

        # These ".orig" files are for checking that the file is restored back
        # to the original state
        self.local_conf_orig = os.path.join(self.tempdir, "local.conf.orig")
        self.bblayers_conf_orig = os.path.join(self.tempdir,
                                               "bblayers.conf.orig")
        shutil.copyfile(self.local_conf, self.local_conf_orig)
        shutil.copyfile(self.bblayers_conf, self.bblayers_conf_orig)

    def test_files_are_restored(self):
        cmd = """python helpers/runbitbake.py --pokydir={} """ \
              """-t junk -b {} """ \
              """--extraconf={} """ \
              """--extralayers={}""".format(self.pokydir, self.builddir,
                                            self.extraconf, self.extralayers)

        subprocess.call(cmd.split(), stderr=sys.stderr, stdout=sys.stdout,
                        shell=False)

        with open(self.local_conf_orig, "r") as f:
            origlines = f.readlines()
        with open(self.local_conf, "r") as f:
            newlines = f.readlines()
        self.assertListEqual(origlines, newlines)

        with open(self.bblayers_conf_orig, "r") as f:
            origlines = f.readlines()
        with open(self.bblayers_conf, "r") as f:
            newlines = f.readlines()
        self.assertListEqual(origlines, newlines)


class AddExtraTest(RunBitbakeTestBase):
    def setUp(self):
        super(AddExtraTest, self).setUp()
        # Since we are importing a file in the source directory, this prevents
        # cluttering the directory with a .pyc file.
        sys.dont_write_bytecode = True

        self.runbitbake = os.path.join("helpers", "runbitbake.py")
        self.module = imp.load_source("", self.runbitbake)

        self.addextra_tempdir = os.path.join(self.tempdir, "addextratmp")
        os.mkdir(self.addextra_tempdir)

    def test_addextra_changed_files(self):
        addextra = self.module.addextra
        addextra(self.addextra_tempdir, self.builddir, "local.conf",
                 [self.extraconf])

        with open(self.extraconf, "r") as f:
            extraconflines = set(f.readlines())
        with open(self.local_conf, "r") as f:
            localconflines = set(f.readlines())

        intersection = extraconflines & localconflines
        self.assertListEqual(sorted(intersection), sorted(extraconflines))


@pytest.fixture
def bitbake_signal_path():
    oldenv = os.environ.copy()

    # Add the fake bitbake to path
    os.environ['PATH'] = "./tests/unit/signals:" + os.environ['PATH']

    yield

    os.environ = oldenv


@pytest.fixture
def pokydir(tmpdir):
    # runbitbake.py requires --pokydir with a "oe-init-build-env" script
    setupscript = tmpdir.mkdir("poky").join("oe-init-build-env")
    with open(str(setupscript), "w"):
        pass

    yield tmpdir.join("poky")


test_signal = [signal.SIGINT, signal.SIGTERM]


@pytest.mark.parametrize("test_signal", test_signal)
def test_signal_forward(bitbake_signal_path, tmpdir, pokydir, test_signal):
    import time
    cmd = "python helpers/runbitbake.py -t foo --pokydir {} -b {}"
    cmd = cmd.format(pokydir, str(tmpdir))

    p = subprocess.Popen(shlex.split(cmd),
                         stdout=subprocess.PIPE,
                         stderr=subprocess.STDOUT, shell=False,
                         universal_newlines=True)

    # Wait til program is started before sending the signal
    count = 0
    while count < 30:
        stdout = p.stdout.readline()

        if 'Waiting for signal' not in stdout:
            time.sleep(1)
            count = count + 1
        else:
            break

    # Now that the process is running send it a signal
    p.send_signal(test_signal)

    stdout, stderr = p.communicate()
    assert "Handler called with signal {}\n".format(test_signal) == stdout

if __name__ == '__main__':
    unittest.main()
Download .txt
gitextract_1r_6ch8g/

├── .github/
│   └── workflows/
│       └── build-test-deploy.yml
├── .gitignore
├── COPYING
├── LICENSE
├── README.md
├── build-install-dumb-init.sh
├── build_container.sh
├── buildall.sh
├── deploy.sh
├── distro-entry.sh
├── dockerfiles/
│   ├── alma/
│   │   ├── alma-8/
│   │   │   └── alma-8-base/
│   │   │       └── Dockerfile
│   │   └── alma-9/
│   │       └── alma-9-base/
│   │           └── Dockerfile
│   ├── debian/
│   │   ├── debian-10/
│   │   │   └── debian-10-base/
│   │   │       └── Dockerfile
│   │   ├── debian-11/
│   │   │   └── debian-11-base/
│   │   │       └── Dockerfile
│   │   └── debian-12/
│   │       └── debian-12-base/
│   │           └── Dockerfile
│   ├── fedora/
│   │   ├── fedora-39/
│   │   │   └── fedora-39-base/
│   │   │       └── Dockerfile
│   │   └── fedora-40/
│   │       └── fedora-40-base/
│   │           └── Dockerfile
│   ├── opensuse/
│   │   ├── opensuse-15.4/
│   │   │   └── opensuse-15.4-base/
│   │   │       └── Dockerfile
│   │   ├── opensuse-15.5/
│   │   │   └── opensuse-15.5-base/
│   │   │       └── Dockerfile
│   │   └── opensuse-15.6/
│   │       └── opensuse-15.6-base/
│   │           └── Dockerfile
│   ├── templates/
│   │   └── Dockerfile.builder
│   └── ubuntu/
│       ├── ubuntu-18.04/
│       │   └── ubuntu-18.04-base/
│       │       └── Dockerfile
│       ├── ubuntu-20.04/
│       │   └── ubuntu-20.04-base/
│       │       └── Dockerfile
│       ├── ubuntu-22.04/
│       │   └── ubuntu-22.04-base/
│       │       └── Dockerfile
│       └── ubuntu-24.04/
│           └── ubuntu-24.04-base/
│               └── Dockerfile
├── helpers/
│   └── runbitbake.py
├── install-buildtools-make.sh
├── install-buildtools.sh
└── tests/
    ├── container/
    │   ├── smoke.sh
    │   ├── vnc-in-container-test.sh
    │   └── vnc-test.sh
    └── unit/
        ├── signals/
        │   └── bitbake
        └── test_runbitbake.py
Download .txt
SYMBOL INDEX (19 symbols across 2 files)

FILE: helpers/runbitbake.py
  function addextra (line 25) | def addextra(tempdir, builddir, name, extralist):
  function restore_files (line 62) | def restore_files(tempdir, builddir, conffiles):
  function handler (line 72) | def handler(signum, frame):

FILE: tests/unit/test_runbitbake.py
  class RunBitbakeTestBase (line 21) | class RunBitbakeTestBase(unittest.TestCase):
    method setUp (line 22) | def setUp(self):
    method tearDown (line 70) | def tearDown(self):
  class ExitCodeTest (line 74) | class ExitCodeTest(RunBitbakeTestBase):
    method setUp (line 75) | def setUp(self):
    method tearDown (line 82) | def tearDown(self):
    method test_exit_code_non_zero (line 86) | def test_exit_code_non_zero(self):
  class ConfFilesTest (line 93) | class ConfFilesTest(RunBitbakeTestBase):
    method setUp (line 94) | def setUp(self):
    method test_files_are_restored (line 105) | def test_files_are_restored(self):
  class AddExtraTest (line 128) | class AddExtraTest(RunBitbakeTestBase):
    method setUp (line 129) | def setUp(self):
    method test_addextra_changed_files (line 141) | def test_addextra_changed_files(self):
  function bitbake_signal_path (line 156) | def bitbake_signal_path():
  function pokydir (line 168) | def pokydir(tmpdir):
  function test_signal_forward (line 181) | def test_signal_forward(bitbake_signal_path, tmpdir, pokydir, test_signal):
Condensed preview — 33 files, each showing path, character count, and a content snippet. Download the .json file or copy for the full structured content (96K chars).
[
  {
    "path": ".github/workflows/build-test-deploy.yml",
    "chars": 1403,
    "preview": "name: yocto-container build and test\non:\n  push:\n    branches:\n      - master\n  pull_request:\n\n  # Allow for manually ru"
  },
  {
    "path": ".gitignore",
    "chars": 65,
    "preview": "dockerfiles/*/*/*-builder/Dockerfile\n*.pyc\n*.pyo\n*.orig\n*.rej\n*~\n"
  },
  {
    "path": "COPYING",
    "chars": 18092,
    "preview": "                    GNU GENERAL PUBLIC LICENSE\n                       Version 2, June 1991\n\n Copyright (C) 1989, 1991 Fr"
  },
  {
    "path": "LICENSE",
    "chars": 18092,
    "preview": "                    GNU GENERAL PUBLIC LICENSE\n                       Version 2, June 1991\n\n Copyright (C) 1989, 1991 Fr"
  },
  {
    "path": "README.md",
    "chars": 15,
    "preview": "# yocto-docker\n"
  },
  {
    "path": "build-install-dumb-init.sh",
    "chars": 2231,
    "preview": "#!/bin/bash\n\n# build-install-dumb-init.sh\n#\n# Copyright (C) 2017-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL"
  },
  {
    "path": "build_container.sh",
    "chars": 2386,
    "preview": "#!/bin/bash\n\n# build-container.sh\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-onl"
  },
  {
    "path": "buildall.sh",
    "chars": 2044,
    "preview": "#!/bin/bash\n\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nPIDS=()\n# some sys"
  },
  {
    "path": "deploy.sh",
    "chars": 1270,
    "preview": "#!/bin/bash\n# Copyright (C) 2016-2021 Intel Corporation\n# Copyright (C) 2022 Konsulko Group\n#\n# SPDX-License-Identifier:"
  },
  {
    "path": "distro-entry.sh",
    "chars": 722,
    "preview": "#!/bin/bash\n# Copyright (C) 2019-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nRELEASE=\"4.1\"\n\nif ["
  },
  {
    "path": "dockerfiles/alma/alma-8/alma-8-base/Dockerfile",
    "chars": 1934,
    "preview": "# alama-8-base\n# Copyright (C) 2015-2020 Intel Corporation\n# Copyright (C) 2022 Konsulko Group\n#\n# SPDX-License-Identifi"
  },
  {
    "path": "dockerfiles/alma/alma-9/alma-9-base/Dockerfile",
    "chars": 1859,
    "preview": "# alama-9-base\n# Copyright (C) 2015-2020 Intel Corporation\n# Copyright (C) 2022 Konsulko Group\n#\n# SPDX-License-Identifi"
  },
  {
    "path": "dockerfiles/debian/debian-10/debian-10-base/Dockerfile",
    "chars": 1773,
    "preview": "# debian-10-base\n# Copyright (C) 2015-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nFROM debian:10"
  },
  {
    "path": "dockerfiles/debian/debian-11/debian-11-base/Dockerfile",
    "chars": 1460,
    "preview": "# debian-11-base\n# Copyright (C) 2015-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nFROM debian:11"
  },
  {
    "path": "dockerfiles/debian/debian-12/debian-12-base/Dockerfile",
    "chars": 1458,
    "preview": "# debian-12-base\n# Copyright (C) 2015-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nFROM debian:12"
  },
  {
    "path": "dockerfiles/fedora/fedora-39/fedora-39-base/Dockerfile",
    "chars": 1872,
    "preview": "# fedora-39-base\n# Copyright (C) 2021 Intel Corporation\n# Copyright (C) 2021-2024 Konsulko Group\n#\n# SPDX-License-Identi"
  },
  {
    "path": "dockerfiles/fedora/fedora-40/fedora-40-base/Dockerfile",
    "chars": 2000,
    "preview": "# fedora-40-base\n# Copyright (C) 2021 Intel Corporation\n# Copyright (C) 2021-2024 Konsulko Group\n#\n# SPDX-License-Identi"
  },
  {
    "path": "dockerfiles/opensuse/opensuse-15.4/opensuse-15.4-base/Dockerfile",
    "chars": 1931,
    "preview": "# opensuse-15.4-base\n# Copyright (C) 2015-2020 Intel Corporation\n# Copyright (C) 2022 Konsulko Group\n#\n# SPDX-License-Id"
  },
  {
    "path": "dockerfiles/opensuse/opensuse-15.5/opensuse-15.5-base/Dockerfile",
    "chars": 1883,
    "preview": "# opensuse-15.5-base\n# Copyright (C) 2015-2020 Intel Corporation\n# Copyright (C) 2022-2024 Konsulko Group\n#\n# SPDX-Licen"
  },
  {
    "path": "dockerfiles/opensuse/opensuse-15.6/opensuse-15.6-base/Dockerfile",
    "chars": 1908,
    "preview": "# opensuse-15.6-base\n# Copyright (C) 2015-2020 Intel Corporation\n# Copyright (C) 2022-2024 Konsulko Group\n#\n# SPDX-Licen"
  },
  {
    "path": "dockerfiles/templates/Dockerfile.builder",
    "chars": 490,
    "preview": "# DISTRO_TO_BUILD-builder\n# Copyright (C) 2015-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nFROM "
  },
  {
    "path": "dockerfiles/ubuntu/ubuntu-18.04/ubuntu-18.04-base/Dockerfile",
    "chars": 1739,
    "preview": "# ubuntu-18.04-base\n# Copyright (C) 2015-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nFROM ubuntu"
  },
  {
    "path": "dockerfiles/ubuntu/ubuntu-20.04/ubuntu-20.04-base/Dockerfile",
    "chars": 1727,
    "preview": "# ubuntu-20.04-base\n# Copyright (C) 2020-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nFROM ubuntu"
  },
  {
    "path": "dockerfiles/ubuntu/ubuntu-22.04/ubuntu-22.04-base/Dockerfile",
    "chars": 1760,
    "preview": "# ubuntu-22.04-base\n# Copyright (C) 2020-2021 Intel Corporation\n# Copyright (C) 2022 Konsulko Group\n#\n# SPDX-License-Ide"
  },
  {
    "path": "dockerfiles/ubuntu/ubuntu-24.04/ubuntu-24.04-base/Dockerfile",
    "chars": 1718,
    "preview": "# ubuntu-24.04-base\n# Copyright (C) 2020-2021 Intel Corporation\n# Copyright (C) 2022-2024 Konsulko Group\n#\n# SPDX-Licens"
  },
  {
    "path": "helpers/runbitbake.py",
    "chars": 5225,
    "preview": "#!/usr/bin/env python3\n\n# runbitbake.py\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2"
  },
  {
    "path": "install-buildtools-make.sh",
    "chars": 894,
    "preview": "#! /bin/bash\n\n# install-buildtools-make.sh\n#\n# Copyright (C) 2020-2021 Intel Corporation\n# Copyright (C) 2022 Konsulko G"
  },
  {
    "path": "install-buildtools.sh",
    "chars": 861,
    "preview": "#! /bin/bash\n\n# install-buildtools.sh\n#\n# Copyright (C) 2020-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0"
  },
  {
    "path": "tests/container/smoke.sh",
    "chars": 1447,
    "preview": "#!/bin/bash\n\n# smoke.sh\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nset -"
  },
  {
    "path": "tests/container/vnc-in-container-test.sh",
    "chars": 1632,
    "preview": "#!/bin/bash\n\n# vnc-in-container.sh\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-on"
  },
  {
    "path": "tests/container/vnc-test.sh",
    "chars": 537,
    "preview": "#!/bin/bash\n\n# vnc-test.sh\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nse"
  },
  {
    "path": "tests/unit/signals/bitbake",
    "chars": 628,
    "preview": "#!/usr/bin/env python3\n\n# bitbake.py\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-"
  },
  {
    "path": "tests/unit/test_runbitbake.py",
    "chars": 7005,
    "preview": "#!/usr/bin/env python3\n#\n# Copyright (C) 2016-2021 Intel Corporation\n#\n# SPDX-License-Identifier: GPL-2.0-only\n#\n\nimport"
  }
]

About this extraction

This page contains the full source code of the crops/yocto-dockerfiles GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 33 files (88.0 KB), approximately 24.1k tokens, and a symbol index with 19 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.

Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.

Copied to clipboard!