diff --git a/.readthedocs.yaml b/.readthedocs.yaml index cbf23382b3de4131342664f0b95b397b18816e68..601e0cbc58e864deb341513e14b4ff9f28d2dd59 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -1,14 +1,15 @@ version: 2 build: - os: ubuntu-20.04 + os: ubuntu-22.04 tools: - python: "3.10" + python: "3.11" python: install: - requirements: ./requirements.txt sphinx: configuration: source/conf.py formats: + - htmlzip - pdf - epub diff --git a/LICENSE b/LICENSE index 00d17607a1617f8556e2220f559dc4382087dbd5..d128c56cc5895441f11d45efd78b77a742b421c9 100644 --- a/LICENSE +++ b/LICENSE @@ -1,21 +1,675 @@ -MIT License - -Copyright (c) 2022 C3SL - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/> + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. 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 +them 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 prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. 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. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey 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; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If 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 convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU 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 that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + 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. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +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. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + 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 +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + Documentation for C3SL's nonexistent (yet) DevOps team. + Copyright (C) 2024 C3SL + + 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 3 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, see <https://www.gnu.org/licenses/>. + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Docs DevOps Copyright (C) 2024 C3SL + This program 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, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +<https://www.gnu.org/licenses/>. + + The GNU 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. But first, please read +<https://www.gnu.org/licenses/why-not-lgpl.html>. + diff --git a/Pipfile b/Pipfile index be06865d8d8e5a411349e4c57f003aa1086225c0..0687abb7a59ab72618ecf57cbdf13511748342bf 100644 --- a/Pipfile +++ b/Pipfile @@ -5,11 +5,17 @@ name = "pypi" [packages] sphinx = "*" -sphinx-rtd-theme = "*" commitizen = "*" pre-commit = "*" +sphinxcontrib-svgbob = "*" +furo = "*" +sphinx-autobuild = "*" +sphinx-inline-tabs = "*" +sphinx-copybutton = "*" +sphinx-tippy = "*" +myst-parser = "*" [dev-packages] [requires] -python_version = "3.11.6" +python_version = "3.11.8" diff --git a/Pipfile.lock b/Pipfile.lock index f499edca000f7d873e8bcc3de6d80a0ce4a81693..0109eaf446286d92ebbc93fa16b6b51a77d589ef 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -1,11 +1,11 @@ { "_meta": { "hash": { - "sha256": "5e7c92feb3fdac19e95729ddb49531249a09e34a38586247eaaa859c6c367a07" + "sha256": "134f7e01a3d320dba42feb4468a15d77b81c3f8452310220458e7ec212d30cda" }, "pipfile-spec": 6, "requires": { - "python_version": "3.11.6" + "python_version": "3.11.8" }, "sources": [ { @@ -26,11 +26,11 @@ }, "argcomplete": { "hashes": [ - "sha256:e44f4e7985883ab3e73a103ef0acd27299dbfe2dfed00142c35d4ddd3005901d", - "sha256:f3e49e8ea59b4026ee29548e24488af46e30c9de57d48638e24f54a1ea1000a2" + "sha256:bf7900329262e481be5a15f56f19736b376df6f82ed27576fa893652c5de6c23", + "sha256:c12355e0494c76a2a7b73e3a59b09024ca0ba1e279fb9ed6c1b82d5b74b6a70c" ], "markers": "python_version >= '3.8'", - "version": "==3.2.2" + "version": "==3.2.3" }, "babel": { "hashes": [ @@ -40,6 +40,14 @@ "markers": "python_version >= '3.7'", "version": "==2.14.0" }, + "beautifulsoup4": { + "hashes": [ + "sha256:74e3d1928edc070d21748185c46e3fb33490f22f52a3addee9aee0f4f7781051", + "sha256:b80878c9f40111313e55da8ba20bdba06d8fa3969fc68304167741bbf9e082ed" + ], + "markers": "python_full_version >= '3.6.0'", + "version": "==4.12.3" + }, "certifi": { "hashes": [ "sha256:0569859f95fc761b18b45ef421b1290a0f65f147e92a1e5eb3e635f9a5e4e66f", @@ -162,12 +170,11 @@ }, "commitizen": { "hashes": [ - "sha256:3c799dc0ffb2c99d021edd32de55ddce182635bf6129ac6abf223696ccbdd1a7", - "sha256:5345a118f2a0b2b8fcfc5fcfea7945f8c984803836a1735199d469e865be4efb" + "sha256:42c1d29ba6a64ddbc6d9952f4bcc2ac7094956e27e47e96c931895e2659e6cee", + "sha256:7e3272725216aa3049e258bb438e0097e07607712325f5ce71d9a0bdf7805370" ], "index": "pypi", - "markers": "python_version >= '3.8'", - "version": "==3.14.0" + "version": "==3.18.0" }, "decli": { "hashes": [ @@ -200,13 +207,21 @@ "markers": "python_version >= '3.8'", "version": "==3.13.1" }, + "furo": { + "hashes": [ + "sha256:3548be2cef45a32f8cdc0272d415fcb3e5fa6a0eb4ddfe21df3ecf1fe45a13cf", + "sha256:4d6b2fe3f10a6e36eb9cc24c1e7beb38d7a23fc7b3c382867503b7fcac8a1e02" + ], + "index": "pypi", + "version": "==2024.1.29" + }, "identify": { "hashes": [ - "sha256:161558f9fe4559e1557e1bff323e8631f6a0e4837f7497767c1782832f16b62d", - "sha256:d40ce5fcd762817627670da8a7d8d8e65f24342d14539c59488dc603bf662e34" + "sha256:10a7ca245cfcd756a554a7288159f72ff105ad233c7c4b9c6f0f4d108f5f6791", + "sha256:c4de0081837b211594f8e877a6b4fad7ca32bbfc1a9307fdd61c28bfe923f13e" ], "markers": "python_version >= '3.8'", - "version": "==2.5.33" + "version": "==2.5.35" }, "idna": { "hashes": [ @@ -226,11 +241,11 @@ }, "importlib-metadata": { "hashes": [ - "sha256:4805911c3a4ec7c3966410053e9ec6a1fecd629117df5adee56dfc9432a1081e", - "sha256:f238736bb06590ae52ac1fab06a3a9ef1d8dce2b7a35b5ab329371d6c8f5d2cc" + "sha256:198f568f3230878cb1b44fbd7975f87906c22336dba2e4a7f05278c281fbd792", + "sha256:f4bc4c0c070c490abf4ce96d715f68e95923320370efb66143df00199bb6c100" ], "markers": "python_version >= '3.8'", - "version": "==7.0.1" + "version": "==7.0.2" }, "jinja2": { "hashes": [ @@ -240,6 +255,21 @@ "markers": "python_version >= '3.7'", "version": "==3.1.3" }, + "livereload": { + "hashes": [ + "sha256:776f2f865e59fde56490a56bcc6773b6917366bce0c267c60ee8aaf1a0959869", + "sha256:ad4ac6f53b2d62bb6ce1a5e6e96f1f00976a32348afedcb4b6d68df2a1d346e4" + ], + "version": "==2.6.3" + }, + "markdown-it-py": { + "hashes": [ + "sha256:355216845c60bd96232cd8d8c40e8f9765cc86f46880e43a8fd22dc1a1a8cab1", + "sha256:e3f60a94fa066dc52ec76661e37c851cb232d92f9886b15cb560aaada2df8feb" + ], + "markers": "python_version >= '3.8'", + "version": "==3.0.0" + }, "markupsafe": { "hashes": [ "sha256:00e046b6dd71aa03a41079792f8473dc494d564611a8f89bbbd7cb93295ebdcf", @@ -306,6 +336,30 @@ "markers": "python_version >= '3.7'", "version": "==2.1.5" }, + "mdit-py-plugins": { + "hashes": [ + "sha256:b51b3bb70691f57f974e257e367107857a93b36f322a9e6d44ca5bf28ec2def9", + "sha256:d8ab27e9aed6c38aa716819fedfde15ca275715955f8a185a8e1cf90fb1d2c1b" + ], + "markers": "python_version >= '3.8'", + "version": "==0.4.0" + }, + "mdurl": { + "hashes": [ + "sha256:84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8", + "sha256:bb413d29f5eea38f31dd4754dd7377d4465116fb207585f97bf925588687c1ba" + ], + "markers": "python_version >= '3.7'", + "version": "==0.1.2" + }, + "myst-parser": { + "hashes": [ + "sha256:7c36344ae39c8e740dad7fdabf5aa6fc4897a813083c6cc9990044eb93656b14", + "sha256:ea929a67a6a0b1683cdbe19b8d2e724cd7643f8aa3e7bb18dd65beac3483bead" + ], + "index": "pypi", + "version": "==2.0.0" + }, "nodeenv": { "hashes": [ "sha256:d51e0c37e64fbf47d017feac3145cdbb58836d7eee8c6f6d3b6880c5456227d2", @@ -316,11 +370,11 @@ }, "packaging": { "hashes": [ - "sha256:048fb0e9405036518eaaf48a55953c750c11e1a1b68e0dd1a9d62ed0c092cfc5", - "sha256:8c491190033a9af7e1d931d0b5dacc2ef47509b34dd0de67ed209b5203fc88c7" + "sha256:2ddfb553fdf02fb784c234c7ba6ccc288296ceabec964ad2eae3777778130bc5", + "sha256:eb82c5e3e56209074766e6885bb04b8c38a0c015d0a30036ebe7ece34c9989e9" ], "markers": "python_version >= '3.7'", - "version": "==23.2" + "version": "==24.0" }, "platformdirs": { "hashes": [ @@ -332,12 +386,11 @@ }, "pre-commit": { "hashes": [ - "sha256:c255039ef399049a5544b6ce13d135caba8f2c28c3b4033277a788f434308376", - "sha256:d30bad9abf165f7785c15a21a1f46da7d0677cb00ee7ff4c579fd38922efe15d" + "sha256:ba637c2d7a670c10daedc059f5c49b5bd0aadbccfcd7ec15592cf9665117532c", + "sha256:c3ef34f463045c88658c5b99f38c1e297abdcc0ff13f98d3370055fbbfabc67e" ], "index": "pypi", - "markers": "python_version >= '3.9'", - "version": "==3.6.0" + "version": "==3.6.2" }, "prompt-toolkit": { "hashes": [ @@ -430,11 +483,19 @@ }, "setuptools": { "hashes": [ - "sha256:385eb4edd9c9d5c17540511303e39a147ce2fc04bc55289c322b9e5904fe2c05", - "sha256:be1af57fc409f93647f2e8e4573a142ed38724b8cdd389706a867bb4efcf1e78" + "sha256:02fa291a0471b3a18b2b2481ed902af520c69e8ae0919c13da936542754b4c56", + "sha256:5c0806c7d9af348e6dd3777b4f4dbb42c7ad85b190104837488eab9a7c945cf8" ], "markers": "python_version >= '3.8'", - "version": "==69.0.3" + "version": "==69.1.1" + }, + "six": { + "hashes": [ + "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926", + "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254" + ], + "markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'", + "version": "==1.16.0" }, "snowballstemmer": { "hashes": [ @@ -443,23 +504,61 @@ ], "version": "==2.2.0" }, + "soupsieve": { + "hashes": [ + "sha256:5663d5a7b3bfaeee0bc4372e7fc48f9cff4940b3eec54a6451cc5299f1097690", + "sha256:eaa337ff55a1579b6549dc679565eac1e3d000563bcb1c8ab0d0fefbc0c2cdc7" + ], + "markers": "python_version >= '3.8'", + "version": "==2.5" + }, "sphinx": { "hashes": [ "sha256:1e09160a40b956dc623c910118fa636da93bd3ca0b9876a7b3df90f07d691560", "sha256:9a5160e1ea90688d5963ba09a2dcd8bdd526620edbb65c328728f1b2228d5ab5" ], "index": "pypi", - "markers": "python_version >= '3.9'", "version": "==7.2.6" }, - "sphinx-rtd-theme": { + "sphinx-autobuild": { "hashes": [ - "sha256:bd5d7b80622406762073a04ef8fadc5f9151261563d47027de09910ce03afe6b", - "sha256:ec93d0856dc280cf3aee9a4c9807c60e027c7f7b461b77aeffed682e68f0e586" + "sha256:63fd87ab7505872a89aef468ce6503f65e794a195f4ae62269db3b85b72d4854", + "sha256:cb9d2121a176d62d45471624872afc5fad7755ad662738abe400ecf4a7954303" ], "index": "pypi", - "markers": "python_version >= '3.6'", - "version": "==2.0.0" + "version": "==2024.2.4" + }, + "sphinx-basic-ng": { + "hashes": [ + "sha256:9ec55a47c90c8c002b5960c57492ec3021f5193cb26cebc2dc4ea226848651c9", + "sha256:eb09aedbabfb650607e9b4b68c9d240b90b1e1be221d6ad71d61c52e29f7932b" + ], + "markers": "python_version >= '3.7'", + "version": "==1.0.0b2" + }, + "sphinx-copybutton": { + "hashes": [ + "sha256:4cf17c82fb9646d1bc9ca92ac280813a3b605d8c421225fd9913154103ee1fbd", + "sha256:fb543fd386d917746c9a2c50360c7905b605726b9355cd26e9974857afeae06e" + ], + "index": "pypi", + "version": "==0.5.2" + }, + "sphinx-inline-tabs": { + "hashes": [ + "sha256:06809ac613f7c48ddd6e2fa588413e3fe92cff2397b56e2ccf0b0218f9ef6a78", + "sha256:5df2f13f602c158f3f5f6c509e008aeada199a8c76d97ba3aa2822206683bebc" + ], + "index": "pypi", + "version": "==2023.4.21" + }, + "sphinx-tippy": { + "hashes": [ + "sha256:bc5a012dd13d079d2049727617b4c52f7fb9779510f1784571bab1550c73e621", + "sha256:e1004bc0bf0463274c603065ea961f88b14cd2616a1438264f1fedfc280db1aa" + ], + "index": "pypi", + "version": "==0.4.1" }, "sphinxcontrib-applehelp": { "hashes": [ @@ -485,14 +584,6 @@ "markers": "python_version >= '3.9'", "version": "==2.0.5" }, - "sphinxcontrib-jquery": { - "hashes": [ - "sha256:1620739f04e36a2c779f1a131a2dfd49b2fd07351bf1968ced074365933abc7a", - "sha256:f936030d7d0147dd026a4f2b5a57343d233f1fc7b363f68b3d4f1cb0993878ae" - ], - "markers": "python_version >= '2.7'", - "version": "==4.1" - }, "sphinxcontrib-jsmath": { "hashes": [ "sha256:2ec2eaebfb78f3f2078e73666b1415417a116cc848b72e5172e596c871103178", @@ -517,6 +608,28 @@ "markers": "python_version >= '3.9'", "version": "==1.1.10" }, + "sphinxcontrib-svgbob": { + "hashes": [ + "sha256:004c0f4072544e844db33c3def31c9706003b1a00e9f4efbdaec48ebc5467ef6", + "sha256:07a10cd490bc53d3a9d800ade846cfe21d7f35845c0f391b15e6f88b4c4f3850", + "sha256:123b38e26ba4481910f683a7ff06e8f20d5895acb66d927dd588f4173d9e4727", + "sha256:1a4c676159cf503fdcfa2d86568014dd4918798ab8418a0bb57bbb71554c0f51", + "sha256:1d3fa3a4fad4ba4b6a7b17e454106a13058f8fc86135c64db05599ea26cf5f5b", + "sha256:3c87b17af9fb8aa28fc22746ec96d308088753d3a2ee51261407091060bea994", + "sha256:79b9aafd3f58fa2baf25bfb391834359c75398ef77660fb7515c31e3af1413c3", + "sha256:7e77f4d6a162b424a048abba478290e5da602f2f23636e27eff2c9728d751115", + "sha256:7f402369fa116120416171c38d383ecc97fcf6d31c16cb4e0f79933b931fc34d", + "sha256:a4add4f89a642b3e980c2f3bfe3da66ef6b520ec8eccbb9ff626dc9cb9758cc2", + "sha256:abf91c43890165f83cfca9b52442f09661aaec062172a749854e448def5dcd19", + "sha256:ad7c84aa986f4f3e15baa0cac8f3ec3e490de721d88b8d43d9344a02f8fc6133", + "sha256:aeec747011bc0a2d216b20c09c650d44638d1d321091bac5d9c00a9adc858347", + "sha256:be181768392300ccedee70c8918e7a66ff19471b7cfe0c320fb24f2abbf71972", + "sha256:c4ef2babe43545cc4521010a6c762a64ae8e346b0bb591e11c72819085d3012f", + "sha256:f50d37c46e03aaaaac899a8438bd8565f0921c3f7b7f3f0a4f7fff5cf4986067" + ], + "index": "pypi", + "version": "==0.2.1" + }, "termcolor": { "hashes": [ "sha256:9297c0df9c99445c2412e832e882a7884038a25617c60cea2ad69488d4040d63", @@ -527,27 +640,44 @@ }, "tomlkit": { "hashes": [ - "sha256:75baf5012d06501f07bee5bf8e801b9f343e7aac5a92581f20f80ce632e6b5a4", - "sha256:b0a645a9156dc7cb5d3a1f0d4bab66db287fcb8e0430bdd4664a095ea16414ba" + "sha256:5cd82d48a3dd89dee1f9d64420aa20ae65cfbd00668d6f094d7578a78efbb77b", + "sha256:7ca1cfc12232806517a8515047ba66a19369e71edf2439d0f5824f91032b6cc3" ], "markers": "python_version >= '3.7'", - "version": "==0.12.3" + "version": "==0.12.4" + }, + "tornado": { + "hashes": [ + "sha256:02ccefc7d8211e5a7f9e8bc3f9e5b0ad6262ba2fbb683a6443ecc804e5224ce0", + "sha256:10aeaa8006333433da48dec9fe417877f8bcc21f48dda8d661ae79da357b2a63", + "sha256:27787de946a9cffd63ce5814c33f734c627a87072ec7eed71f7fc4417bb16263", + "sha256:6f8a6c77900f5ae93d8b4ae1196472d0ccc2775cc1dfdc9e7727889145c45052", + "sha256:71ddfc23a0e03ef2df1c1397d859868d158c8276a0603b96cf86892bff58149f", + "sha256:72291fa6e6bc84e626589f1c29d90a5a6d593ef5ae68052ee2ef000dfd273dee", + "sha256:88b84956273fbd73420e6d4b8d5ccbe913c65d31351b4c004ae362eba06e1f78", + "sha256:e43bc2e5370a6a8e413e1e1cd0c91bedc5bd62a74a532371042a18ef19e10579", + "sha256:f0251554cdd50b4b44362f73ad5ba7126fc5b2c2895cc62b14a1c2d7ea32f212", + "sha256:f7894c581ecdcf91666a0912f18ce5e757213999e183ebfc2c3fdbf4d5bd764e", + "sha256:fd03192e287fbd0899dd8f81c6fb9cbbc69194d2074b38f384cb6fa72b80e9c2" + ], + "markers": "python_version > '2.7'", + "version": "==6.4" }, "urllib3": { "hashes": [ - "sha256:051d961ad0c62a94e50ecf1af379c3aba230c66c710493493560c0c223c49f20", - "sha256:ce3711610ddce217e6d113a2732fafad960a03fd0318c91faa79481e35c11224" + "sha256:450b20ec296a467077128bff42b73080516e71b56ff59a60a02bef2232c4fa9d", + "sha256:d0570876c61ab9e520d776c38acbbb5b05a776d3f9ff98a5c8fd5162a444cf19" ], "markers": "python_version >= '3.8'", - "version": "==2.2.0" + "version": "==2.2.1" }, "virtualenv": { "hashes": [ - "sha256:4238949c5ffe6876362d9c0180fc6c3a824a7b12b80604eeb8085f2ed7460de3", - "sha256:bf51c0d9c7dd63ea8e44086fa1e4fb1093a31e963b86959257378aef020e1f1b" + "sha256:961c026ac520bac5f69acb8ea063e8a4f071bcc9457b9c1f28f6b085c511583a", + "sha256:e08e13ecdca7a0bd53798f356d5831434afa5b07b93f0abdf0797b7a06ffe197" ], "markers": "python_version >= '3.7'", - "version": "==20.25.0" + "version": "==20.25.1" }, "wcwidth": { "hashes": [ diff --git a/README.md b/README.md index 48785618bf2540c5354bd1900c2a7ac91ea5c87b..633c95ee3614245a4c4154a30194513ff18545f9 100644 --- a/README.md +++ b/README.md @@ -1,41 +1,38 @@ -# Template Read the docs -Este repositório server de template para documentação do readthedocs do C3SL -[docs](docs.c3sl.ufpr.br). +# Documentação (oficial?) de DevOps do C3SL + +Documentação criada pelos roots para os e baseada em ReadTheDocs. [[_TOC_]] -# Como começar -O primeiro passo é realizar o folk do template e depois clonar o folk. +# Organização do repositório + +A gestão dos pacotes é feita através do pipenv. Para instalar use `pipenv install`, +e para entrar no ambiente virtual, `pipenv shell`, onde será possível rodar +`pipenv run make html` para gerar a documentação localmente. Há também um modo +de desenvolvimento que pode ser invocado rodando `pipenv run make dev`. -Após clonar, edite a documentação localizada em `sources` e quando terminar faça push para o gitlab -e link no [docs](docs.c3sl.ufpr.br). +Para usar o pre-commit hook que reformata os arquivos documentação ao fazer +commit, depois de clonar o repositório rode `pipenv run pre-commit install`. +O repositório é dedicado a documentação e está organizado da seguinte maneira: + * `build/`: Diretório onde os arquivos compilados vão. + * `cz.yaml`: Arquivo de configuração do commitizen. + * `.git`: Diretório de configuração do git. + * `.gitignore`: Arquivo com padrões de nomes que o git deve ignorar ao realizar `git add` ou `git stage`. + * `Makefile`: Makefile para fazer o build da documentação, resultado vai para o diretório `build`. + * `Pipfile`: Arquivo do pipenv para criar ambiente do python para fazer build. + * `Pipfile.lock`: Arquivo do pipenv para criar ambiente do python para fazer build. + * `.pre-commit-config.yaml`: Arquivo de configuração do pre-commit. + * `README.md`: Este arquivo. + * `.readthedocs.yaml`: Arquivo de configuração do readthedocs. + * `requirements.txt`: Arquivos com listas de modulos python para fazer build da documentação, deve ser igual ao `Pipfile`, pode ser gerado com `pipenv requirements > requirements.txt`. + * `LICENSE`: Arquivo de licença. + * `.gitlab-ci.yml`: Arquivo do Gitlab-CI. + * `source/`: Diretório da documentação. + * `conf.py`: Arquivo de configuração do sphinx. + * `index.md`: Primeira página da documentação. + * `pages/`: Diretório com as páginas da documentação. + * `_static/`: Diretório para armazenar arquivos estáticos, como imagens, gifs e etc. + * `_templates/`: Diretório para armazenar estilização das páginas, css, html e etc. + * `_ext/`: Diretório para armazenar extensões customizadas. -# Organização do repositório -O repositório é dedicado a documentação e esta orgazanizado da seguinte maneira: - * `build/` Diretório onde os arquivos compilados vão. - * `cz.yaml` Arquivo de configuração do commitizen - * `.git` Diretório de configuração do git - * `.gitignore`Arquivo com padrões de nomes que o git deve ignorar ao realizar `git add` ou `git - stage` - * `Makefile` Makefile para fazer o build da documentação, resultado vai para o diretório `build` - * `Pipfile` Arquivo do pipenv para criar ambiente do python para fazer build - * `Pipfile.lock` Arquivo do pipenv para criar ambiente do python para fazer build - * `.pre-commit-config.yaml` Arquivo de configuração do pre-commit - * `README.md` arquivo de readme do repositório. - * `.readthedocs.yaml` Arquivo de configuração do readthedocs - * `requirements.txt` Arquivos com listas de modulos python para fazer build da documentação, deve - ser igual ao `Pipfile` - * `LICENSE` arquivo de licença - * `.gitlab-ci.yml` Arquivo do Gitlab CI - * `scripts/` Diretório com scripts variados. - * `generate-requeriments.sh` Script que gera o arquivo `requirements.txt` a partir do `Pipfile`. - * `source/` Diretório da documentação. - * `conf.py` Arquivo de configuração do sphinx - * `index.rst` Primeira página da documentação - * `pages/` Diretório com as páginas da documentação - * `quickstart-rst.rst` Página com dicas de rst com sphinx - * `quickstart-conf.rst` Página com dicas de configuração do `conf.py` - * `quickstart-rdt.rst` Página de como incluir um repositório em [docs](docs.c3sl.ufpr.br) - * `_static/` Diretório para armazenar arquivos estáticos, como imagens, gifs e etc. - * `_templates/` Diretório para armazenar estilização das páginas, css, html e etc. diff --git a/requirements.txt b/requirements.txt index e315ff6d0b734bb6cd11c2dba42a2bb1f16f9fd8..59f31ae6bde750b746291054a1bf88605a325d37 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,45 +1,59 @@ -i https://pypi.org/simple -alabaster==0.7.16; python_version >= '3.9' -argcomplete==3.2.2; python_version >= '3.8' -babel==2.14.0; python_version >= '3.7' -certifi==2024.2.2; python_version >= '3.6' -cfgv==3.4.0; python_version >= '3.8' -charset-normalizer==3.3.2; python_full_version >= '3.7.0' -colorama==0.4.6; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6' -commitizen==3.14.0; python_version >= '3.8' -decli==0.6.1; python_version >= '3.7' +alabaster==0.7.16 ; python_version >= '3.9' +argcomplete==3.2.2 ; python_version >= '3.8' +babel==2.14.0 ; python_version >= '3.7' +beautifulsoup4==4.12.3 ; python_full_version >= '3.6.0' +certifi==2024.2.2 ; python_version >= '3.6' +cfgv==3.4.0 ; python_version >= '3.8' +charset-normalizer==3.3.2 ; python_full_version >= '3.7.0' +colorama==0.4.6 ; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6' +commitizen==3.15.0 +decli==0.6.1 ; python_version >= '3.7' distlib==0.3.8 -docutils==0.20.1; python_version >= '3.7' -filelock==3.13.1; python_version >= '3.8' -identify==2.5.33; python_version >= '3.8' -idna==3.6; python_version >= '3.5' -imagesize==1.4.1; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' -importlib-metadata==7.0.1; python_version >= '3.8' -jinja2==3.1.3; python_version >= '3.7' -markupsafe==2.1.5; python_version >= '3.7' -nodeenv==1.8.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6' -packaging==23.2; python_version >= '3.7' -platformdirs==4.2.0; python_version >= '3.8' -pre-commit==3.6.0; python_version >= '3.9' -prompt-toolkit==3.0.36; python_full_version >= '3.6.2' -pygments==2.17.2; python_version >= '3.7' -pyyaml==6.0.1; python_version >= '3.6' -questionary==2.0.1; python_version >= '3.8' -requests==2.31.0; python_version >= '3.7' -setuptools==69.0.3; python_version >= '3.8' +docutils==0.20.1 ; python_version >= '3.7' +filelock==3.13.1 ; python_version >= '3.8' +furo==2024.1.29 +identify==2.5.35 ; python_version >= '3.8' +idna==3.6 ; python_version >= '3.5' +imagesize==1.4.1 ; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' +importlib-metadata==7.0.1 ; python_version >= '3.8' +jinja2==3.1.3 ; python_version >= '3.7' +livereload==2.6.3 +markdown-it-py==3.0.0 ; python_version >= '3.8' +markupsafe==2.1.5 ; python_version >= '3.7' +mdit-py-plugins==0.4.0 ; python_version >= '3.8' +mdurl==0.1.2 ; python_version >= '3.7' +myst-parser==2.0.0 +nodeenv==1.8.0 ; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6' +packaging==23.2 ; python_version >= '3.7' +platformdirs==4.2.0 ; python_version >= '3.8' +pre-commit==3.6.2 +prompt-toolkit==3.0.36 ; python_full_version >= '3.6.2' +pygments==2.17.2 ; python_version >= '3.7' +pyyaml==6.0.1 ; python_version >= '3.6' +questionary==2.0.1 ; python_version >= '3.8' +requests==2.31.0 ; python_version >= '3.7' +setuptools==69.1.0 ; python_version >= '3.8' +six==1.16.0 ; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3' snowballstemmer==2.2.0 -sphinx==7.2.6; python_version >= '3.9' -sphinx-rtd-theme==2.0.0; python_version >= '3.6' -sphinxcontrib-applehelp==1.0.8; python_version >= '3.9' -sphinxcontrib-devhelp==1.0.6; python_version >= '3.9' -sphinxcontrib-htmlhelp==2.0.5; python_version >= '3.9' -sphinxcontrib-jquery==4.1; python_version >= '2.7' -sphinxcontrib-jsmath==1.0.1; python_version >= '3.5' -sphinxcontrib-qthelp==1.0.7; python_version >= '3.9' -sphinxcontrib-serializinghtml==1.1.10; python_version >= '3.9' -termcolor==2.4.0; python_version >= '3.8' -tomlkit==0.12.3; python_version >= '3.7' -urllib3==2.2.0; python_version >= '3.8' -virtualenv==20.25.0; python_version >= '3.7' +soupsieve==2.5 ; python_version >= '3.8' +sphinx==7.2.6 +sphinx-autobuild==2024.2.4 +sphinx-basic-ng==1.0.0b2 ; python_version >= '3.7' +sphinx-copybutton==0.5.2 +sphinx-inline-tabs==2023.4.21 +sphinx-tippy==0.4.1 +sphinxcontrib-applehelp==1.0.8 ; python_version >= '3.9' +sphinxcontrib-devhelp==1.0.6 ; python_version >= '3.9' +sphinxcontrib-htmlhelp==2.0.5 ; python_version >= '3.9' +sphinxcontrib-jsmath==1.0.1 ; python_version >= '3.5' +sphinxcontrib-qthelp==1.0.7 ; python_version >= '3.9' +sphinxcontrib-serializinghtml==1.1.10 ; python_version >= '3.9' +sphinxcontrib-svgbob==0.2.1 +termcolor==2.4.0 ; python_version >= '3.8' +tomlkit==0.12.3 ; python_version >= '3.7' +tornado==6.4 ; python_version > '2.7' +urllib3==2.2.1 ; python_version >= '3.8' +virtualenv==20.25.0 ; python_version >= '3.7' wcwidth==0.2.13 -zipp==3.17.0; python_version >= '3.8' +zipp==3.17.0 ; python_version >= '3.8' diff --git a/scripts/generate-requeriments.sh b/scripts/generate-requeriments.sh deleted file mode 100755 index ad05737a0b2827698eec9b148472a8c99b0d85ba..0000000000000000000000000000000000000000 --- a/scripts/generate-requeriments.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/usr/bin/sh -pipenv lock -r > requirements.txt diff --git a/source/_ext/inline_svgbob.py b/source/_ext/inline_svgbob.py new file mode 100644 index 0000000000000000000000000000000000000000..e923fbb70e9bcfd7b4c08fb1b418fb3562db1b07 --- /dev/null +++ b/source/_ext/inline_svgbob.py @@ -0,0 +1,35 @@ +import os +import sphinx.transforms +import xml.etree.ElementTree as ET +from docutils.nodes import image, raw +from sphinxcontrib.svgbob.node import svgbob + + +class InlineSvgbob(sphinx.transforms.SphinxTransform): + default_priority = 11 + + def apply(self, **kwargs): + source = os.path.dirname(self.document["source"]) + for node in self.document.traverse(image): + if "svgbob" in node: + filepath = os.path.join(source, node["uri"]) + root = ET.parse(filepath).getroot() + for elem in root.iter(): + elem.tag = elem.tag.split("}")[1] + root.remove(root.find("style")) + node.replace_self( + raw( + classes=[f'align-{node["align"]}'] if "align" in node else [], + text=ET.tostring(root).decode(), + format="html", + ) + ) + + +def setup(app): + app.add_transform(InlineSvgbob) + return { + "version": "0.1", + "parallel_read_safe": True, + "parallel_write_safe": True, + } diff --git a/source/_static/c3sl.png b/source/_static/c3sl.png new file mode 100644 index 0000000000000000000000000000000000000000..291732f53947ec9f673ce616244e2f61ab37156d Binary files /dev/null and b/source/_static/c3sl.png differ diff --git a/source/_static/fonts/iosevka-fixed/LATEST_RELEASE b/source/_static/fonts/iosevka-fixed/LATEST_RELEASE new file mode 100644 index 0000000000000000000000000000000000000000..f6733da096748b3690b7d5c864c912f97e498055 --- /dev/null +++ b/source/_static/fonts/iosevka-fixed/LATEST_RELEASE @@ -0,0 +1 @@ +27.3.5 diff --git a/source/_static/fonts/iosevka-fixed/LICENSE b/source/_static/fonts/iosevka-fixed/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..261eeb9e9f8b2b4b0d119366dda99c6fd7d35c64 --- /dev/null +++ b/source/_static/fonts/iosevka-fixed/LICENSE @@ -0,0 +1,201 @@ + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/source/_static/fonts/iosevka-fixed/README.md b/source/_static/fonts/iosevka-fixed/README.md new file mode 100644 index 0000000000000000000000000000000000000000..691e81e78ac12a6433c8105e7d8a247cf87bd4ea --- /dev/null +++ b/source/_static/fonts/iosevka-fixed/README.md @@ -0,0 +1,6 @@ +# Iosevka Fixed WebFont 27.3.5 + +## How to use + +- Add `<link href="https://iosevka-webfonts.github.io/iosevka-fixed/iosevka-fixed.css" rel="stylesheet" />` to your `<head>`. +- Use `fontFamily: 'Iosevka Fixed Web'` or `font-family: 'Iosevka Fixed Web'`. diff --git a/source/_static/fonts/iosevka-fixed/iosevka-fixed.css b/source/_static/fonts/iosevka-fixed/iosevka-fixed.css new file mode 100644 index 0000000000000000000000000000000000000000..5d33fd275e27654bac655a03672577a459e4d0a4 --- /dev/null +++ b/source/_static/fonts/iosevka-fixed/iosevka-fixed.css @@ -0,0 +1,53 @@ +@font-face { + font-family: 'Iosevka Fixed Web'; + font-display: swap; + font-weight: 400; + font-stretch: normal; + font-style: normal; + src: url('woff2/iosevka-fixed-regular.woff2') format('woff2'); +} + +@font-face { + font-family: 'Iosevka Fixed Web'; + font-display: swap; + font-weight: 400; + font-stretch: normal; + font-style: oblique; + src: url('woff2/iosevka-fixed-oblique.woff2') format('woff2'); +} + +@font-face { + font-family: 'Iosevka Fixed Web'; + font-display: swap; + font-weight: 400; + font-stretch: normal; + font-style: italic; + src: url('woff2/iosevka-fixed-italic.woff2') format('woff2'); +} + +@font-face { + font-family: 'Iosevka Fixed Web'; + font-display: swap; + font-weight: 700; + font-stretch: normal; + font-style: normal; + src: url('woff2/iosevka-fixed-bold.woff2') format('woff2'); +} + +@font-face { + font-family: 'Iosevka Fixed Web'; + font-display: swap; + font-weight: 700; + font-stretch: normal; + font-style: oblique; + src: url('woff2/iosevka-fixed-boldoblique.woff2') format('woff2'); +} + +@font-face { + font-family: 'Iosevka Fixed Web'; + font-display: swap; + font-weight: 700; + font-stretch: normal; + font-style: italic; + src: url('woff2/iosevka-fixed-bolditalic.woff2') format('woff2'); +} diff --git a/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-bold.woff2 b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-bold.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..fc46a4a70704da73824b6c32e38591e9e90f1c51 Binary files /dev/null and b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-bold.woff2 differ diff --git a/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-bolditalic.woff2 b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-bolditalic.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..181f660546f4dedcc0d20b9af405d68e3f722c1a Binary files /dev/null and b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-bolditalic.woff2 differ diff --git a/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-boldoblique.woff2 b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-boldoblique.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..b441ba9aa5a0f50a6ad5a1ee356b9315afe017df Binary files /dev/null and b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-boldoblique.woff2 differ diff --git a/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-italic.woff2 b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-italic.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..58db98084cb5590f84cc162da444700c33e56dff Binary files /dev/null and b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-italic.woff2 differ diff --git a/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-oblique.woff2 b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-oblique.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..150bb265f85b3745e8ec408bd9d72e075c788133 Binary files /dev/null and b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-oblique.woff2 differ diff --git a/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-regular.woff2 b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-regular.woff2 new file mode 100644 index 0000000000000000000000000000000000000000..95af9389e87375c609e1ebfc3177f3b26f7f6223 Binary files /dev/null and b/source/_static/fonts/iosevka-fixed/woff2/iosevka-fixed-regular.woff2 differ diff --git a/source/_static/root-logo.png b/source/_static/root-logo.png new file mode 100644 index 0000000000000000000000000000000000000000..d196f5a7611b6cd6d5ec99f5fac6e82909c46dc0 Binary files /dev/null and b/source/_static/root-logo.png differ diff --git a/source/_static/svgbob.css b/source/_static/svgbob.css new file mode 100644 index 0000000000000000000000000000000000000000..fcc469daf8e0cfa61609a4c4b2ed2805435a919e --- /dev/null +++ b/source/_static/svgbob.css @@ -0,0 +1,77 @@ +.svgbob line, .svgbob path, .svgbob circle, .svgbob rect, .svgbob polygon { + stroke: var(--color-content-foreground); + stroke-width: 2; + stroke-opacity: 1; + fill-opacity: 1; + stroke-linecap: round; + stroke-linejoin: miter; +} + +.svgbob text { + white-space: pre; + fill: var(--color-content-foreground); + font-family: Iosevka Fixed Web, monospace; + font-size: 14px; +} + +.svgbob rect.backdrop { + stroke: none; + fill: var(--color-content-background); +} + +.svgbob .broken { + stroke-dasharray: 8; +} + +.svgbob .filled { + fill: var(--color-content-foreground); +} + +.svgbob .bg_filled { + fill: var(--color-content-background); + stroke-width: 1; +} + +.svgbob .nofill { + fill: var(--color-content-background); +} + +.svgbob .end_marked_arrow { + marker-end: url(#arrow); +} + +.svgbob .start_marked_arrow { + marker-start: url(#arrow); +} + +.svgbob .end_marked_diamond { + marker-end: url(#diamond); +} + +.svgbob .start_marked_diamond { + marker-start: url(#diamond); +} + +.svgbob .end_marked_circle { + marker-end: url(#circle); +} + +.svgbob .start_marked_circle { + marker-start: url(#circle); +} + +.svgbob .end_marked_open_circle { + marker-end: url(#open_circle); +} + +.svgbob .start_marked_open_circle { + marker-start: url(#open_circle); +} + +.svgbob .end_marked_big_open_circle { + marker-end: url(#big_open_circle); +} + +.svgbob .start_marked_big_open_circle { + marker-start: url(#big_open_circle); +} diff --git a/source/_templates/page.html b/source/_templates/page.html new file mode 100644 index 0000000000000000000000000000000000000000..b0e48f20d3c10a81340400ef58d5140b29161687 --- /dev/null +++ b/source/_templates/page.html @@ -0,0 +1,3 @@ +{% set next = None %} +{% set prev = None %} +{% extends "!page.html" %} diff --git a/source/conf.py b/source/conf.py index 6662fa38c74012bcffc43f0ff22099d733b01881..a8697da786d23d9218c13c917d3f4c78f41763c9 100644 --- a/source/conf.py +++ b/source/conf.py @@ -1,3 +1,8 @@ +import os +import sys + +sys.path.append(os.path.abspath("./_ext")) + # Configuration file for the Sphinx documentation builder. # # For the full list of built-in configuration values, see the documentation: @@ -6,22 +11,53 @@ # -- Project information ----------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information -project = "Template-RDT" -copyright = "2022, Odair M." -author = "Odair M." +project = "DevOps C3SL" +copyright = "2024 C3SL" +author = "Carlos Iago, Tiago Conte, Guiusepe Oneda, Marcus Reisdoefer, Fernando Kiotheka, Odair Dutkin" # -- General configuration --------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration -extensions = [] +language = "pt" templates_path = ["_templates"] exclude_patterns = [] -language = "pt" +extensions = [ + "sphinxcontrib.svgbob", + "sphinx.ext.todo", + "sphinx_inline_tabs", + "sphinx_copybutton", + "sphinx_tippy", + "myst_parser", + "inline_svgbob", +] + +myst_enable_extensions = [ + "colon_fence", + "deflist", + "fieldlist", +] + +myst_heading_anchors = 2 + +copybutton_prompt_text = r">>> |\$ |.+:.+# |.+@.+> |<.+>" +copybutton_prompt_is_regexp = True +copybutton_line_continuation_character = "\\" +copybutton_here_doc_delimiter = "EOF" +copybutton_copy_empty_lines = False + +todo_include_todos = True # -- Options for HTML output ------------------------------------------------- # https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output -html_theme = "alabaster" -html_static_path = ["_static"] +html_theme = "furo" +html_static_path = ["_static", "_static/fonts/iosevka-fixed/"] +html_css_files = ["fonts/iosevka-fixed/iosevka-fixed.css", "svgbob.css"] + +html_logo = "_static/root-logo.png" +html_theme_options = { + "sidebar_hide_name": True, + "source_edit_link": "https://gitlab.c3sl.ufpr.br/c3sl/c3docs/devops/-/blob/main/source/{filename}", +} diff --git a/source/index.md b/source/index.md new file mode 100644 index 0000000000000000000000000000000000000000..f6f61e28795a4e7d24f9c82b67c02e53e80037af --- /dev/null +++ b/source/index.md @@ -0,0 +1,46 @@ +# DevOps do C3SL + +```{image} _static/root-logo.png +:align: center +:alt: Root +:width: 200px +``` + +```{image} _static/c3sl.png +:align: center +:alt: C3SL UFPR +:target: https://www.c3sl.ufpr.br +:width: 150px +``` + +```{toctree} +:caption: Conceitos +:glob: true +:maxdepth: 1 + +pages/concepts/* +``` + +```{toctree} +:caption: Políticas +:glob: true +:maxdepth: 1 + +pages/policies/* +``` + +```{toctree} +:caption: Guias e Tutoriais +:glob: true +:maxdepth: 1 + +pages/guides/* +``` + +```{toctree} +:caption: "Propostas de melhoria" +:glob: true +:maxdepth: 1 + +pages/proposals/* +``` diff --git a/source/index.rst b/source/index.rst deleted file mode 100644 index 1c4171537c196500d3697d249efdaf0c354d9d97..0000000000000000000000000000000000000000 --- a/source/index.rst +++ /dev/null @@ -1,20 +0,0 @@ -.. Template-RDT documentation master file, created by - sphinx-quickstart on Wed Nov 2 22:52:13 2022. - You can adapt this file completely to your liking, but it should at least - contain the root `toctree` directive. - -Welcome to Template-RDT's documentation! -======================================== - -.. toctree:: - :maxdepth: 2 - :caption: Contents: - - - -Indices and tables -================== - -* :ref:`genindex` -* :ref:`modindex` -* :ref:`search` diff --git a/source/pages/concepts/; b/source/pages/concepts/; new file mode 100644 index 0000000000000000000000000000000000000000..1dd15fef71cefa48772bfb1fb6ecd7419259ea4a --- /dev/null +++ b/source/pages/concepts/; @@ -0,0 +1,44 @@ +# Fundamentos do Docker + +Assume-se que quem ler essa documentação é familiarizado com os conceitos +básicos de Docker[^cite_docker_concepts]. + +## Trabalhando com **contêineres** +### Hello, World! + +## O arquivo **Dockerfile** + +## Analisando **imagens** + +## Persistindo mudanças no disco com **volumes** + +## Uma introdução a **redes** (de Docker) + +## Docker Compose +### docker-compose.yml +... + +## Exemplo de deploy +TODO: exemplo de backend e frontend configurando o nginx + +:::{admonition} Esse **não é** o método preferido. +:class: note +Idealmente com Docker **separa-se o código da +infraestrutura** completamente. + +Logo, o fluxo de trabalho ideal para um projeto em Docker seria +realizar o `push` de sua imagem para um *registry* e o ambiente +de deploy fazer o `pull` dela. Tarefas que podem até ser realizadas +por times distintos. + +Esse tipo de automação pode ser integrada ao desenvolvimento +utilizando ferramentas como GitLabCI[^cite_gitlab_ci] para +realizar esse deploy com qualquer *merge* na branch `main`, +por exemplo. + +Entretanto, no momento em que esse documento é escrito esse é +o método utilizado no C3SL. +::: + + +[^cite_docker_concepts]: [Conceitos básicos de Docker](../concepts/docker.md). diff --git a/source/pages/concepts/docker.md b/source/pages/concepts/docker.md new file mode 100644 index 0000000000000000000000000000000000000000..850a3fa12e36b09eec2d6cbb34b6dbc747ec69d4 --- /dev/null +++ b/source/pages/concepts/docker.md @@ -0,0 +1,131 @@ +# Docker + +Este é essencialmente um 'TLDR' da documentação oficial[^cite_docker_docs]. A +ideia é fazer com que o leitor tenha uma ideia básica do funcionamento e dos +conceitos chave de Docker. + +## O que é Docker? + +'Docker é uma plataforma aberta para desenvolver, transportar e executar +aplicações. Docker permite **separar aplicações de sua infraestrutura**, o +que viabiliza entregar software mais rápido. Com Docker é possível gerenciar +a infraestrutura do mesmo jeito que se gerenciam as aplicações. Ao tirar +vantagem das metodologias de transporte, teste e implantação de código do +Docker é possível reduzir significativamente o atraso ente escrever código +e executar ele em produção.' + +Resumindo a sopa de palavras: + +Docker permite criar 'caixinhas' que contém tudo o que é necessário para +executar a aplicação, o que deixa esse software independente do sistema +em que ele deve executar. + +## Como Docker funciona? +### Docker Engine +### Docker vs. Máquina Virtual + +## **Resumindo** conceitos importantes +### Contêiner +- Containers são pacotes de software leves, autônomos e executáveis que incluem + tudo o que é necessário para executar um software, incluindo o código, ferramentas + do sistema, bibliotecas do sistema e configurações. +- Eles isolam o software de seu ambiente, garantindo que ele seja executado + consistentemente, independentemente de onde seja implantado. +- Os contêineres utilizam o kernel do sistema operacional hospedeiro e + compartilham recursos com outros contêineres, tornando-os eficientes e + portáteis. +- É criado com base em uma imagem; + +### Imagem +- Imagens são *templates*, somente leitura, que contém as **instruções** para criar + um contêiner Docker. +- Elas encapsulam o código do aplicativo junto com suas dependências, + bibliotecas e ambiente de execução. +- Uma imagem é criada utilizando um arquivo chamado `Dockerfile`, um arquivo + de texto que especifica as etapas necessárias para construir um contêiner. +- As imagens do Docker podem ser criadas a partir do zero ou podem ser baseadas + em imagens existentes disponíveis no Docker Hub ou em outros *registries* + +### Registry +- *Registries* são repositórios onde as imagens Docker são armazenadas e + distribuídas. +- O *registry* mais popular é o DockerHub[^cite_docker_hub]. Ele é público + e o padrão para imagens Docker, onde os usuários podem encontrar e + compartilhar imagens de contêineres. +- Organizações também podem configurar *registries* privados para armazenar + imagens próprias dentro de sua infraestrutura de rede. **O C3SL tem seu próprio + Docker *Registry***. +- *Registries* permitem versionamento, colaboração e distribuição de imagens + Docker em diferentes ambientes. +- **Abusando do termo**: *registries* como o DockerHub são para o imagens Docker + o que serviços como GitHub são para repositórios Git. Veja o versionamento de + imagens como commits em um repositório. (Lembre que estamos abusando do termo) + +### Volume +- Volumes são uma maneira de persistir dados gerados e usados por contêineres + Docker. Sem volumes qualquer dado escrito no sistema de arquivos de um contêiner + será perdido assim que o contêiner pare. +- Eles fornecem um mecanismo para armazenar e gerenciar dados separadamente do + ciclo de vida do container. +- Os volumes podem ser compartilhados entre containers e também podem ser + montados do sistema hospedeiro, permitindo que os dados persistam mesmo se o + container for interrompido ou excluído. +:::{important} +Em um determinado momento um contêiner contendo um pequeno serviço do C3SL foi +configurado errado, o **volume estava incorreto**. Eventualmente esse contêiner +foi parado e a imagem foi atualizada, o que acarretou na **perda de tudo o +que foi salvo** nesse serviço. +::: + +### Rede +- As redes Docker permitem a comunicação entre contêineres em execução no mesmo + host ou em vários hosts. +- Por padrão, o Docker cria uma rede de ponte para cada host, permitindo que os + contêineres se comuniquem entre si e com o mundo externo, que já basta para a + maioria dos casos de uso. Há no total 7[^cite_docker_networks] tipos de redes + Docker (6 *drivers* distintos). +- Usuários podem criar redes personalizadas para isolar contêineres, + controlar o tráfego e implementar políticas de rede. +- As redes Docker fornecem recursos como resolução DNS, descoberta de serviço e + segmentação de rede, melhorando a flexibilidade e escalabilidade de + aplicativos containerizados. + + +## Por que utilizar Docker? +### '*Never install locally*' +:::{note} +Isso é particularmente relevante quando lida com **dois ou mais gerenciadores +de pacotes**. Um bom exemplo disso são `pip` do Python e `apt` do Debian. É +frequente as instalações de um conflitarem com as do outro, e resolver esse +problema não é trivial. + +Claro, no caso do `pip` há ambientes virtuais para evitar isso, mas Docker também +é um ambiente virtual, e é mais fácil de fazer a aplicação funcionar caso +ela não seja inteiramente em Python, por exemplo. Além das vantagens de +ter uma imagem da aplicação para *deploy* facilitado. +::: +### Executar código legado +Assumindo que tudo foi configurado corretamente. Uma vez que uma aplicação tem uma imagem + +:::{admonition} Um projeto *dockarizado* ficou parado por dois anos e voltou do nada? +:class:{question} +Sem problemas! É só fazer o *deploy* da última imagem de produção! Agora para +continuar o desenvolvimento basta que a documentação[^cite_documentation] do +projeto esteja em ordem (esse é um problema que sempre caberá ao projeto em si). +::: + +### Testes de integração +... + +## Por que não utilizar Docker? +### Dependências complexas +... +### Aplicações de altíssimo desempenho +... +### Aplicações pequenas, simples e isoladas +Um perfeito exemplo disso é um *website*. Caso + +[^cite_docker_docs]: [Primeiros passos com Docker](https://docs.docker.com/get-started/overview/). +[^cite_docker_hub]: [Docker Hub](https://hub.docker.com/). +[^cite_docker_networks]: [*Overview* de redes Docker](https://docs.docker.com/network/#drivers). +[^cite_documentation]: [Guia básico de documentação](../policies/documentation.md). diff --git a/source/pages/concepts/git.md b/source/pages/concepts/git.md new file mode 100644 index 0000000000000000000000000000000000000000..38eeffa4b435cff85e7cf2e13b3b4eef0067097c --- /dev/null +++ b/source/pages/concepts/git.md @@ -0,0 +1 @@ +# Git diff --git a/source/pages/concepts/gitlab-ci.md b/source/pages/concepts/gitlab-ci.md new file mode 100644 index 0000000000000000000000000000000000000000..85c685225c877c52f8afbc884706766a8c1ab098 --- /dev/null +++ b/source/pages/concepts/gitlab-ci.md @@ -0,0 +1 @@ +# GitLab CI diff --git a/source/pages/concepts/linters.md b/source/pages/concepts/linters.md new file mode 100644 index 0000000000000000000000000000000000000000..feea30d1e9ccf7fcf9ca4f002ac37553556a9c36 --- /dev/null +++ b/source/pages/concepts/linters.md @@ -0,0 +1 @@ +# Linters e formatadores diff --git a/source/pages/concepts/testing-code.md b/source/pages/concepts/testing-code.md new file mode 100644 index 0000000000000000000000000000000000000000..276676ab64af8159b19c0cf8ce8763bb6e49fdb4 --- /dev/null +++ b/source/pages/concepts/testing-code.md @@ -0,0 +1 @@ +# Testes de código diff --git a/source/pages/guides/containerize-an-application.md b/source/pages/guides/containerize-an-application.md new file mode 100644 index 0000000000000000000000000000000000000000..eba0ae22c3ef0a51508ea86d35a9b1c5358124d5 --- /dev/null +++ b/source/pages/guides/containerize-an-application.md @@ -0,0 +1 @@ +# Dockarizando uma aplicação diff --git a/source/pages/guides/docker-fundamentals.md b/source/pages/guides/docker-fundamentals.md new file mode 100644 index 0000000000000000000000000000000000000000..9bff00661a056636635e573edb4b9ffc8a1b97ef --- /dev/null +++ b/source/pages/guides/docker-fundamentals.md @@ -0,0 +1,268 @@ +# Fundamentos do Docker + +Assume-se que quem ler essa documentação é familiarizado com os conceitos +básicos de Docker[^cite_docker_concepts]. + +Antes de começar a executar comandos é preciso ter Docker instalado no sistema. +Há documentação oficial[^cite_docker_install] sobre instalação. + +## Trabalhando com contêineres +### Utilizando imagens pré-construídas +Vamos iniciar com prática: pegar uma imagem que já foi construída por alguém e +executar um contêiner baseado nela. Para este guia foi escolhida a imagem do +NodeJS[^cite_nodejs]. + +Execute o comando `docker run node`. A saída deve ser similar à seguinte: + +``` +root@devops:~# docker run node +Unable to find image 'node:latest' locally +latest: Pulling from library/node +7bb465c29149: Pull complete +2b9b41aaa3c5: Pull complete +49b40be4436e: Pull complete +c558fac597f8: Pull complete +449619e06fe3: Pull complete +91b364bb66eb: Pull complete +4974a440c623: Pull complete +43ff5adaa0a2: Pull complete +Digest: sha256:104b26b5d34f9907f1f1e5e51fd9e557845f1a354f07ee9f28814dd9574a6154 +Status: Downloaded newer image for node:latest +root@devops:~# +``` + +Analisando o comando e o *output*: +- Foi requisitado um contêiner em execução utilizando a imagem do Node. +- O sistema não tinha nenhuma imagem do Node, então ele procurou no *registry* + padrão: o DockerHub[^cite_docker_hub]. +- Cada linha que termina com 'Pull complete' é uma camada da imagem baixada. + Veremos mais sobre camadas de imagens depois. +- Após isso um novo contêiner foi criado com base nessa imagem e colocado em + execução. + +Há mais um detalhe: a imagem que foi baixada é `node:latest`. Esse '*latest*' é +uma *tag*, um identificador de versão da imagem. No caso da imagem do NodeJS as +*tags* da imagem são as próprias versões do Node, como `18.19` ou `21.7`. + +Sempre que a *tag* não for especificada a versão mais recente será escolhida. +Como um exemplo vamos rodar `docker run node:18.19`, especificando que queremos +a versão `18.19` do NodeJS: + +``` +root@devops:~# docker run node:18.19 +Unable to find image 'node:18.19' locally +18.19: Pulling from library/node +7bb465c29149: Already exists +2b9b41aaa3c5: Already exists +49b40be4436e: Already exists +c558fac597f8: Already exists +449619e06fe3: Already exists +f52e55fee245: Pull complete +b51b5379e841: Pull complete +806ff1e3aade: Pull complete +Digest: sha256:aa329c613f0067755c0787d2a3a9802c7d95eecdb927d62b910ec1d28689882f +Status: Downloaded newer image for node:18.19 +root@devops:~# +``` + +Note que as primeiras camadas da imagem aparecem como '*Already exists*', isso +pois `node:18.19` é uma versão mais antiga de `node:latest`, logo a base para +ambos é a mesma, mas a versão nova muda algumas coisas. + +Veremos essa questão de *tags* e 'camadas' de imagens mais à frente. + +### Verificando contêineres no sistema +O comando `docker ps` lista os contêineres em execução no sistema. + +``` +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +``` + +Mas onde estão os contêineres que executamos? + +Simples, eles executaram. Uma vez que o processo principal de um contêiner +finaliza ele também encerra a sua execução. + +Para ver contêineres parados no sistema precisamos passar uma flag extra para +o comando `docker ps`: `--all`. + +Em sua forma reduzida: `docker ps -a`. + +``` +root@devops:~# docker ps -a +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +db1fae1ac24f node:18.19 "docker-entrypoint.s…" 4 seconds ago Exited (0) 2 seconds ago objective_williamson +f0c5f39f1c91 node "docker-entrypoint.s…" 9 seconds ago Exited (0) 8 seconds ago keen_shannon +root@devops:~# +``` + +Vamos analisar esse output: +- Cada contêiner tem um id único, assim como um nome único. +- Como não fornecemos um nome para os contêineres o Docker escolheu um nome + para cada um deles. +- O comando executado foi um tal `docker-entrypoint.s...`. Esse é um arquivo + de *entrypoint*, que veremos mais à frente. Por enquanto veja esse comando + apenas como um script que incia tudo o que o contêiner precisa. + +:::{note} +Para mais opções do comando `docker ps` basta executar `docker ps --help`. +::: + +#### Executando um contêiner em modo interativo + +Legal, mas e se quisermos interagir com o contêiner? Para rodar um contêiner +interativo basta passar as flags `--interactive` e `--tty` para o comando. + +Na forma reduzida, nosso comando vira: `docker run -it node`. + +Basicamente, sempre que o usuário for interagir com o contêiner as flags são +`-it`, e se for apenas a *shell* que interage com o contêiner usa-se `-i`. + +``` +root@devops:~# docker run -it node +Welcome to Node.js v21.7.0. +Type ".help" for more information. +> console.log('Hello, World!'); +Hello, World! +undefined +> +``` + +Para sair da *shell* interativa do Node basta teclar `Ctrl+D`. + +:::{note} +Para mais opções do comando `docker run` basta executar `docker run --help`. +::: + +#### Removendo contêineres +Se você rodar `docker ps -a` de novo perceberá que o número de contêineres +parados aumentou. Para não ficar com esse lixo parado basta executar o +comando `docker rm <identificador-do-container>`. + +``` +root@devops:~# docker ps -a +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +5452a05b6ab7 node:18.19 "docker-entrypoint.s…" 6 seconds ago Exited (0) 2 seconds ago pedantic_varahamihira +00b6d2a0de3d node "docker-entrypoint.s…" About a minute ago Exited (0) About a minute ago objective_edison +root@devops:~# docker rm pedantic_varahamihira +pedantic_varahamihira +root@devops:~# docker ps -a +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +00b6d2a0de3d node "docker-entrypoint.s…" About a minute ago Exited (0) About a minute ago objective_edison +root@devops:~# docker rm 00b6d2a0de3d +00b6d2a0de3d +root@devops:~# docker ps -a +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +root@devops:~# +``` + +Note que tanto o identificador do nome quando do id do contêiner servem. + +#### Removendo contêineres automaticamente +Para remover automaticamente um contêiner que você executou é só passar a +flag `--rm` para o comando `docker run <imagem>`. + +``` +root@devops:~# docker ps -a +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +root@devops:~# docker run --rm node +root@devops:~# docker ps -a +CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES +root@devops:~# +``` + +## Lidando com imagens +Como comentado anteriormente, imagens Docker são construídas por camadas. + +Essencialmente 'cada camada é uma linha de um script'. O que ocorre sempre que +um contêiner é criado a partir de uma imagem é que ele pega o contêiner original, +aplica as configurações definidas nas camadas da imagem em ordem, e + +De certa forma o efeito seria o mesmo se você + +:::{note} +Como curiosidade: execute o comando `docker image inspect node`. + +Não veremos isso em detalhes, mas se você pesquisar pelos termos `docker +inspect` você encontrará diversos recursos sobre inspeção de imagens e +contêineres. Isso é extremamente útil para análise do que está realmente +sendo executado no sistema, e talvez ajude a compreender Docker em baixo +nível. +::: + +É possível ver quais imagens estão no seu sistema com o comando `docker image +ls`. E do mesmo modo que contêineres: para remover uma imagem basta executar +`docker image rm <imagem>`, com a tag caso necessário. + +``` +root@devops:~# docker image ls +REPOSITORY TAG IMAGE ID CREATED SIZE +node latest ba29744b7cd0 3 days ago 1.1GB +node 18.19 39e94893115b 3 weeks ago 1.09GB +root@devops:~# docker image rm node:18.19 +Untagged: node:18.19 +Untagged: node@sha256:aa329c613f0067755c0787d2a3a9802c7d95eecdb927d62b910ec1d28689882f +Deleted: sha256:39e94893115b118c1ada01fbdd42e954bb70f847933e91c3bcda278c96ad4ca2 +Deleted: sha256:f4617b988ec85d56956f9c94329121c6a0435ca8a7ab9da5881704cd3da19c83 +Deleted: sha256:f9a979819cd5b9ea2ee0acc379a6ec61813326bd33901ca53fccf3e15db8efbd +Deleted: sha256:82f9d9a7995035f61d6044546e6e28a5acb688b6028a2c071d3c06816b399fe1 +root@devops:~# docker image ls +REPOSITORY TAG IMAGE ID CREATED SIZE +node latest ba29744b7cd0 3 days ago 1.1GB +root@devops:~# +``` + +### Criando uma imagem com um Dockerfile +TODO: exemplo com backend Node + +#### EXPOSE <PORT> + +### *Attatched* e *detatched* + +## Persistindo mudanças no disco com volumes + +## Uma introdução às redes + +## Docker Compose +Como orquestrar múltiplos contêineres elegantemente? + +### `docker-compose.yml` +... + +## TODO: Utilizando um registry +Falar de `pull`, `login`, `push` e etc. + +## Exemplo de *deploy* manual +TODO: fazer o exemplo + +:::{admonition} Esse não é necessariamente o melhor método. +:class: note +Idealmente com Docker **separa-se o código da infraestrutura** completamente. + +Logo, um fluxo de trabalho ideal para um projeto em Docker seria realizar o +`push` de sua imagem para um *registry* e o ambiente de deploy fazer o `pull` +dela. Tarefas que podem até ser realizadas por times distintos. (Claro, há +outros métodos também) + +Esse tipo de automação pode ser integrada ao desenvolvimento utilizando +ferramentas como GitLabCI[^cite_gitlab_ci] para realizar esse deploy com +qualquer *merge* na branch `main`, por exemplo. +::: + +## TODO: Colinha de Docker +- `docker run <nome-da-imagem>:<tag>`: Cria e executa um contêiner com base na imagem com + versão especificada pela *tag*. +- `docker pull <nome-da-imagem>:<tag>`: Faz *download* da imagem especificada + com a versão da *tag*. +- `docker ps`: Lista contêineres em execução. +- `docker ps -a`: Lista todos os contêineres na máquina (tanto parados quanto + em execução). +- `docker ps -q`: Lista IDs dos contêineres em execução. +- `docker stop $(docker ps -q)`: Para **todos** os contêineres em execução. + + +[^cite_docker_concepts]: [Conceitos básicos de Docker](../concepts/docker.md). +[^cite_gitlab_ci]: [Introdução ao GitLab CI](../concepts/gitlab-ci.md). +[^cite_docker_install]: [Instalando Docker](https://docs.docker.com/engine/install/). +[^cite_nodejs]: [NodeJS](https://nodejs.org/). +[^cite_docker_hub]: [DockerHub](https://hub.docker.com/). diff --git a/source/pages/guides/frontent-to-s3.md b/source/pages/guides/frontent-to-s3.md new file mode 100644 index 0000000000000000000000000000000000000000..e1d2ae62d5f9f05bafbfa7fe0321b394f965ea5e --- /dev/null +++ b/source/pages/guides/frontent-to-s3.md @@ -0,0 +1,3 @@ +# Servindo frontend utilizando S3 + +## Integrando com GitLab CI diff --git a/source/pages/guides/troubleshooting.md b/source/pages/guides/troubleshooting.md new file mode 100644 index 0000000000000000000000000000000000000000..2cbdf4fffb8bb8b2b23dec53ca3877719e10d232 --- /dev/null +++ b/source/pages/guides/troubleshooting.md @@ -0,0 +1 @@ +# Troubleshooting básico diff --git a/source/pages/policies/development-lifecycle.md b/source/pages/policies/development-lifecycle.md new file mode 100644 index 0000000000000000000000000000000000000000..1035fde7349698ebd4b190fb58ecfb80d940356e --- /dev/null +++ b/source/pages/policies/development-lifecycle.md @@ -0,0 +1 @@ +# Ciclo de desenvolvimento no C3SL diff --git a/source/pages/policies/documentation.md b/source/pages/policies/documentation.md new file mode 100644 index 0000000000000000000000000000000000000000..eaeb73c30ba8ccc11b504df870f915fc3721870a --- /dev/null +++ b/source/pages/policies/documentation.md @@ -0,0 +1 @@ +# Como documentar um projeto diff --git a/source/pages/policies/upgrading.md b/source/pages/policies/upgrading.md new file mode 100644 index 0000000000000000000000000000000000000000..5f6ab7086716be32489fd232fbe7fff4c187aa28 --- /dev/null +++ b/source/pages/policies/upgrading.md @@ -0,0 +1 @@ +# Como fazer upgrade de serviços, aplicações ou VMs