Re: RPM packaging help

2023-08-14 Thread Andrew Heath
Maxwell,
Does this look better
diff --git a/receptor.spec b/receptor.spec
index 40ed2ac..3b9f9a2 100644
--- a/receptor.spec
+++ b/receptor.spec
@@ -1,13 +1,7 @@
 # Generated by go2rpm 1.9.0
-%bcond_without check
-%bcond_without bundled
-%bcond_without golang_library
-%if %{defined rhel}
-%bcond_without bundled
-%endif
-%if %{with bundled}
-%bcond_with golang_library
-%endif
+%bcond check 1
+%bcond bundled 1
+%bcond golang_library %{without bundled}

 %define pyproject_install() %{expand:\\\
 specifier=$(ls %{_pyproject_wheeldir}/*.whl | xargs basename --multiple |
sed -E 's/([^-]+)-([^-]+)-.+\\\.whl/\\\1==\\\2/')
@@ -239,6 +233,7 @@ BuildRequires:  python3-devel
 # For Python tests
 BuildRequires:  psmisc
 BuildRequires:  openssh
+BuildRequires: openssl

 %description %{common_description}

@@ -343,7 +338,7 @@ popd
 %doc README-receptor-python-worker.md
 %{_bindir}/receptor-python-worker
 %{python3_sitelib}/receptor_python_worker/
-%{python3_sitelib}receptor_python_worker-%{version}.dist-info/
+%{python3_sitelib}/receptor_python_worker-%{version}.dist-info/

 %if %{without golang_library}
 %gopkgfiles

On Mon, Aug 14, 2023 at 2:55 PM Maxwell G  wrote:

> On Mon Aug 14, 2023 at 12:49 -0400, Andrew Heath wrote:
> > Ok, I tried rebuilding on my f38 mock system with the spec and changes
> and
> > running into some issues with the check section, I have attached a link
> to
> > the failed section for review. If i comment out the %check section all
> > builds good
>
> You're missing a `BuildRequires: openssl` and
> `%{python3_sitelib}receptor_python_worker-%{version}.dist-info/` is
> missing a slash after `%{python3_sitelib}`.
>
> Also, you should apply the feedback from the previous post to the
> specfile.
>
>
> --
> Best,
>
> Maxwell G (@gotmax23)
> Pronouns: He/They
> ___
> devel mailing list -- devel@lists.fedoraproject.org
> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
> Fedora Code of Conduct:
> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives:
> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
> Do not reply to spam, report it:
> https://pagure.io/fedora-infrastructure/new_issue
>


-- 
Sincerely,
Andrew Heath
aheath1...@gmail.com
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Maxwell G
On Mon Aug 14, 2023 at 12:49 -0400, Andrew Heath wrote:
> Ok, I tried rebuilding on my f38 mock system with the spec and changes and
> running into some issues with the check section, I have attached a link to
> the failed section for review. If i comment out the %check section all
> builds good

You're missing a `BuildRequires: openssl` and
`%{python3_sitelib}receptor_python_worker-%{version}.dist-info/` is
missing a slash after `%{python3_sitelib}`.

Also, you should apply the feedback from the previous post to the
specfile.


-- 
Best,

Maxwell G (@gotmax23)
Pronouns: He/They
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Andrew Heath
*Here is

On Mon, Aug 14, 2023 at 2:14 PM Andrew Heath  wrote:

> Hers the fedorapeople git URL:
> https://fedorapeople.org/cgit/aheath1992/public_git/receptor.git/tree/
>
> On Mon, Aug 14, 2023 at 1:47 PM Andrew Heath  wrote:
>
>> Sure give me a moment to upload it to my fedorapeople page
>>
>> On Mon, Aug 14, 2023 at 1:35 PM Maxwell G  wrote:
>>
>>> On Mon Aug 14, 2023 at 12:49 -0400, Andrew Heath wrote:
>>> > Ok, I tried rebuilding on my f38 mock system with the spec and changes
>>> and
>>> > running into some issues with the check section, I have attached a
>>> link to
>>> > the failed section for review. If i comment out the %check section all
>>> > builds good
>>>
>>> Can you please post the test specfile and SRPM so folks can actually
>>> test it?
>>>
>>>
>>> --
>>> Best,
>>>
>>> Maxwell G (@gotmax23)
>>> Pronouns: He/They
>>> ___
>>> devel mailing list -- devel@lists.fedoraproject.org
>>> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
>>> Fedora Code of Conduct:
>>> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
>>> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
>>> List Archives:
>>> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
>>> Do not reply to spam, report it:
>>> https://pagure.io/fedora-infrastructure/new_issue
>>>
>>
>>
>> --
>> Sincerely,
>> Andrew Heath
>> aheath1...@gmail.com
>>
>
>
> --
> Sincerely,
> Andrew Heath
> aheath1...@gmail.com
>


-- 
Sincerely,
Andrew Heath
aheath1...@gmail.com
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Andrew Heath
Hers the fedorapeople git URL:
https://fedorapeople.org/cgit/aheath1992/public_git/receptor.git/tree/

On Mon, Aug 14, 2023 at 1:47 PM Andrew Heath  wrote:

> Sure give me a moment to upload it to my fedorapeople page
>
> On Mon, Aug 14, 2023 at 1:35 PM Maxwell G  wrote:
>
>> On Mon Aug 14, 2023 at 12:49 -0400, Andrew Heath wrote:
>> > Ok, I tried rebuilding on my f38 mock system with the spec and changes
>> and
>> > running into some issues with the check section, I have attached a link
>> to
>> > the failed section for review. If i comment out the %check section all
>> > builds good
>>
>> Can you please post the test specfile and SRPM so folks can actually
>> test it?
>>
>>
>> --
>> Best,
>>
>> Maxwell G (@gotmax23)
>> Pronouns: He/They
>> ___
>> devel mailing list -- devel@lists.fedoraproject.org
>> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
>> Fedora Code of Conduct:
>> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
>> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
>> List Archives:
>> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
>> Do not reply to spam, report it:
>> https://pagure.io/fedora-infrastructure/new_issue
>>
>
>
> --
> Sincerely,
> Andrew Heath
> aheath1...@gmail.com
>


-- 
Sincerely,
Andrew Heath
aheath1...@gmail.com
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Andrew Heath
Sure give me a moment to upload it to my fedorapeople page

On Mon, Aug 14, 2023 at 1:35 PM Maxwell G  wrote:

> On Mon Aug 14, 2023 at 12:49 -0400, Andrew Heath wrote:
> > Ok, I tried rebuilding on my f38 mock system with the spec and changes
> and
> > running into some issues with the check section, I have attached a link
> to
> > the failed section for review. If i comment out the %check section all
> > builds good
>
> Can you please post the test specfile and SRPM so folks can actually
> test it?
>
>
> --
> Best,
>
> Maxwell G (@gotmax23)
> Pronouns: He/They
> ___
> devel mailing list -- devel@lists.fedoraproject.org
> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
> Fedora Code of Conduct:
> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives:
> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
> Do not reply to spam, report it:
> https://pagure.io/fedora-infrastructure/new_issue
>


-- 
Sincerely,
Andrew Heath
aheath1...@gmail.com
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Maxwell G
On Mon Aug 14, 2023 at 12:49 -0400, Andrew Heath wrote:
> Ok, I tried rebuilding on my f38 mock system with the spec and changes and
> running into some issues with the check section, I have attached a link to
> the failed section for review. If i comment out the %check section all
> builds good

Can you please post the test specfile and SRPM so folks can actually
test it?


-- 
Best,

Maxwell G (@gotmax23)
Pronouns: He/They
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Andrew Heath
Ok, I tried rebuilding on my f38 mock system with the spec and changes and
running into some issues with the check section, I have attached a link to
the failed section for review. If i comment out the %check section all
builds good

https://paste.centos.org/view/228dff0e

On Mon, Aug 14, 2023 at 11:54 AM Maxwell G  wrote:

> On Mon Aug 14, 2023 at 12:49 +0200, Bob Mauchin wrote:
> > On Sun, 13 Aug 2023, 21:39 Maxwell G,  wrote:
> >
> > > > %build
> > > > %if %{with bundled}
> > > > export GO111MODULE=on
> > > > export GOFLAGS=-mod=vendor
> > > > %endif
> > >
> > > I think you can remove these GO* exports.
> > >
> > >
> > >
> > >
> >
> > Why though? If we vendor the stuff, wouldn't it be better to run on Go
> > modules to be closer to upstream?
>
> If you want to run in Go modules mode,
> you need
>
> -export GO111MODULE=on
> +%global gomodulesmode GO111MODULE=off
>
> Due to $SHENANIGANS, the macros ignore the value of the GO111MODULE env
> var and only read from the macro.
> We could probably fix this, but we'd have to make sure it doesn't break
> existing packages that `export GO111MODULE` which is currently a NOOP.
>
> > We should move all the ecosystem to go modules but ENOTIME.
>
> Yeah...
>
> > > > Now we need to add the Python parts. This is actually way more tricky
> > > because the Python
> > > > macros are not designed
> > > > to work with multiple packages inside one repo. It can handles
> "extra"
> > > packages but not
> > > > independent packages.
> > >
> > > > We have added some logic to handle separate record files for each
> > > package.
> > >
> > > Hmm, you shouldn't need to do that.
> > >
> > >
> > >
> > >
> >
> > I don't know, I think it is better to use the Python guidelines and
> macros
> > if possible.
>
> Yes, but redefining the macro instead of doing it manually as the
> maintainers recommend for more complicated usecases doesn't accomplish
> this.
>
>
> > > > # Generated by go2rpm 1.9.0
> > > > %bcond_without check
> > > > %bcond_without bundled
> > > > %bcond_without golang_library
> > > > %if %{defined rhel}
> > > > %bcond_without bundled
> > > > %endif
> > > > %if %{with bundled}
> > > > %bcond_with golang_library
> > > > %endif
> > >
> > > would be better written as
> > >
> > > %bcond check 1
> > > %bcond bundled 1
> > > %bcond golang_library %{without bundled}
> > >
> > >
> > >
> >
> > I need to read the doc regarding bcond compared to bcond_without.
>
> See
> https://rpm-software-management.github.io/rpm/manual/conditionalbuilds.html
> .
>
> --
> Best,
>
> Maxwell G (@gotmax23)
> Pronouns: He/They
> ___
> devel mailing list -- devel@lists.fedoraproject.org
> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
> Fedora Code of Conduct:
> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives:
> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
> Do not reply to spam, report it:
> https://pagure.io/fedora-infrastructure/new_issue
>


-- 
Sincerely,
Andrew Heath
aheath1...@gmail.com
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Maxwell G
On Mon Aug 14, 2023 at 12:49 +0200, Bob Mauchin wrote:
> On Sun, 13 Aug 2023, 21:39 Maxwell G,  wrote:
>
> > > %build
> > > %if %{with bundled}
> > > export GO111MODULE=on
> > > export GOFLAGS=-mod=vendor
> > > %endif
> >
> > I think you can remove these GO* exports.
> >
> >
> >
> >
>
> Why though? If we vendor the stuff, wouldn't it be better to run on Go
> modules to be closer to upstream?

If you want to run in Go modules mode,
you need

-export GO111MODULE=on
+%global gomodulesmode GO111MODULE=off

Due to $SHENANIGANS, the macros ignore the value of the GO111MODULE env
var and only read from the macro.
We could probably fix this, but we'd have to make sure it doesn't break
existing packages that `export GO111MODULE` which is currently a NOOP.

> We should move all the ecosystem to go modules but ENOTIME.

Yeah...

> > > Now we need to add the Python parts. This is actually way more tricky
> > because the Python
> > > macros are not designed
> > > to work with multiple packages inside one repo. It can handles "extra"
> > packages but not
> > > independent packages.
> >
> > > We have added some logic to handle separate record files for each
> > package.
> >
> > Hmm, you shouldn't need to do that.
> >
> >
> >
> >
>
> I don't know, I think it is better to use the Python guidelines and macros
> if possible.

Yes, but redefining the macro instead of doing it manually as the
maintainers recommend for more complicated usecases doesn't accomplish
this.


> > > # Generated by go2rpm 1.9.0
> > > %bcond_without check
> > > %bcond_without bundled
> > > %bcond_without golang_library
> > > %if %{defined rhel}
> > > %bcond_without bundled
> > > %endif
> > > %if %{with bundled}
> > > %bcond_with golang_library
> > > %endif
> >
> > would be better written as
> >
> > %bcond check 1
> > %bcond bundled 1
> > %bcond golang_library %{without bundled}
> >
> >
> >
>
> I need to read the doc regarding bcond compared to bcond_without.

See
https://rpm-software-management.github.io/rpm/manual/conditionalbuilds.html.

-- 
Best,

Maxwell G (@gotmax23)
Pronouns: He/They
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-14 Thread Bob Mauchin
On Sun, 13 Aug 2023, 21:39 Maxwell G,  wrote:

> Hi Robert-André and Andrew,
>
>
> On Sun Aug 13, 2023 at 11:23 +0200, Robert-André Mauchin wrote:
> > On 8/10/23 15:43, Andrew Heath wrote:
> > > All,
> > > My name is Andrew, and I have been working with the Fedora Infra team
> and we are trying to
> > > create some RPMs for some projects that we are working on, one of the
> RPMs we need to create
> > > is for the Ansible receptor[1 ].
> I have a copy of the
> > > spec file from downstream Red Hat that gives some guidance but where
> its a mix of python and
> > > go-lang I was wondering if I could have some guidance from more
> experienced packers on how
> > > to package up the application correctly so that we can get the package
> in use for the Fedora
> > > Infra.
> > >
> > > Links:
> > > [1]: https://github.com/ansible/receptor <
> https://github.com/ansible/receptor>
> > >
> > > --
> > > Sincerely,
> > > Andrew Heath
> > > aheath1...@gmail.com 
> > >
> >
> > Ok, let's roll, you will end up with a Frankstein SPEC, be warned. Here
> is the process:
>
> This is great. Thanks! Here are some notes:
>
> > License:Apache-2.0 AND ISC AND MIT AND BSD-3-Clause AND
> BSD-2-Clause
>
> What did you use to generate that list of licenses?
>
>
>
>

What I've mentioned on Matrix this weekend or last night, the wrapper
around the deps.devs I coded Saturday, and subsequent script I added to the
new tools repo I added to Go-sig on Pagure.

https://github.com/eclipseo/pydepsdev
https://pagure.io/GoSIG/tools



> > %if %{with bundled}
> > Provides:   bundled(golang(github.com/ansible/receptor) = 1.4.1
> > Provides:   bundled(golang(github.com/creack/pty) = 1.1.18
> > Provides:   bundled(golang(github.com/davecgh/go-spew) = 1.1.1
> > Provides:   bundled(golang(github.com/emicklei/go-restful/v3) =
> 3.10.2
> > Provides:   bundled(golang(github.com/fortytw2/leaktest) = 1.3.0
> > Provides:   bundled(golang(github.com/fsnotify/fsnotify) = 1.6.0
> > Provides:   bundled(golang(github.com/ghjm/cmdline) = 0.1.2
> > Provides:   bundled(golang(github.com/go-logr/logr) = 1.2.4
> > Provides:   bundled(golang(github.com/go-openapi/jsonpointer) =
> 0.19.6
> > Provides:   bundled(golang(github.com/go-openapi/jsonreference) =
> 0.20.2
> > Provides:   bundled(golang(github.com/go-openapi/swag) = 0.22.3
> > Provides:   bundled(golang(github.com/go-task/slim-sprig) =
> 0.0.0-20230315git52ccab3
> > Provides:   bundled(golang(github.com/gogo/protobuf) = 1.3.2
> > Provides:   bundled(golang(github.com/golang-jwt/jwt/v4) = 4.5.0
> > Provides:   bundled(golang(github.com/golang/mock) = 1.6.0
> > Provides:   bundled(golang(github.com/golang/protobuf) = 1.5.3
> > Provides:   bundled(golang(github.com/google/gnostic) = 0.6.9
> > Provides:   bundled(golang(github.com/google/go-cmp) = 0.5.9
> > Provides:   bundled(golang(github.com/google/gofuzz) = 1.2.0
> > Provides:   bundled(golang(github.com/google/pprof) =
> 0.0.0-20230502git255e3b9
> > Provides:   bundled(golang(github.com/google/shlex) =
> 0.0.0-20191202gite7afc7f
> > Provides:   bundled(golang(github.com/google/uuid) = 1.3.0
> > Provides:   bundled(golang(github.com/gorilla/websocket) = 1.5.0
> > Provides:   bundled(golang(github.com/imdario/mergo) = 0.3.15
> > Provides:   bundled(golang(github.com/josharian/intern) = 1.0.0
> > Provides:   bundled(golang(github.com/json-iterator/go) = 1.1.12
> > Provides:   bundled(golang(github.com/jupp0r/go-priority-queue) =
> 0.0.0-20160601gitab10738
> > Provides:   bundled(golang(github.com/mailru/easyjson) = 0.7.7
> > Provides:   bundled(golang(github.com/minio/highwayhash) = 1.0.2
> > Provides:   bundled(golang(github.com/moby/spdystream) = 0.2.0
> > Provides:   bundled(golang(github.com/modern-go/concurrent) =
> 0.0.0-20180306gitbacd9c7
> > Provides:   bundled(golang(github.com/modern-go/reflect2) = 1.0.2
> > Provides:   bundled(golang(github.com/munnerz/goautoneg) =
> 0.0.0-20191010gita7dc8b6
> > Provides:   bundled(golang(github.com/onsi/ginkgo/v2) = 2.9.4
> > Provides:   bundled(golang(github.com/pbnjay/memory) =
> 0.0.0-20210728git7b4eea6
> > Provides:   bundled(golang(github.com/pmezard/go-difflib) = 1.0.0
> > Provides:   bundled(golang(github.com/prep/socketpair) =
> 0.0.0-20171228gitc2c6a7f
> > Provides:   bundled(golang(github.com/quic-go/qtls-go1-19) = 0.3.2
> > Provides:   bundled(golang(github.com/quic-go/qtls-go1-20) = 0.2.2
> > Provides:   bundled(golang(github.com/quic-go/quic-go) = 0.34.0
> > Provides:   bundled(golang(github.com/rogpeppe/go-internal) = 1.10.0
> > Provides:   bundled(golang(github.com/songgao/water) =
> 0.0.0-20200317git2b4b6d7
> > Provides:   bundled(golang(github.com/spf13/pflag) = 1.0.5
> > Provides:   bundled(golang(github.com/stretchr/testify) = 1.8.1
> > Provides:   

Re: RPM packaging help

2023-08-13 Thread Brad Smith
On Sun, Aug 13, 2023 at 12:40 PM Maxwell G  wrote:
>
> > Please let me know if there is anything that can be done with the
> > kubernetes rpms to help.
>
> The kubernetes rpms are completely separate from the unbundled
> golang-k8s-* packages and use bundled dependencies as far as I know.
>

Thanks. I had assumed so but was not completely sure.

Best regards

Brad
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-13 Thread Maxwell G
On Sun Aug 13, 2023 at 11:28 -0700, Brad Smith wrote:
> On Sun, Aug 13, 2023 at 9:12 AM Robert-André Mauchin  
> wrote:
> >
>
> >
> > I don't have an ETA on the K8S situation.
> >
>
> Please let me know if there is anything that can be done with the
> kubernetes rpms to help.

The kubernetes rpms are completely separate from the unbundled
golang-k8s-* packages and use bundled dependencies as far as I know.

-- 
Maxwell G (@gotmax23)
Pronouns: He/They
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-13 Thread Maxwell G
Hi Robert-André and Andrew,


On Sun Aug 13, 2023 at 11:23 +0200, Robert-André Mauchin wrote:
> On 8/10/23 15:43, Andrew Heath wrote:
> > All,
> > My name is Andrew, and I have been working with the Fedora Infra team and 
> > we are trying to 
> > create some RPMs for some projects that we are working on, one of the RPMs 
> > we need to create 
> > is for the Ansible receptor[1 ]. I 
> > have a copy of the 
> > spec file from downstream Red Hat that gives some guidance but where its a 
> > mix of python and 
> > go-lang I was wondering if I could have some guidance from more experienced 
> > packers on how 
> > to package up the application correctly so that we can get the package in 
> > use for the Fedora 
> > Infra.
> > 
> > Links:
> > [1]: https://github.com/ansible/receptor 
> > 
> > 
> > -- 
> > Sincerely,
> > Andrew Heath
> > aheath1...@gmail.com 
> > 
>
> Ok, let's roll, you will end up with a Frankstein SPEC, be warned. Here is 
> the process:

This is great. Thanks! Here are some notes:

> License:Apache-2.0 AND ISC AND MIT AND BSD-3-Clause AND BSD-2-Clause

What did you use to generate that list of licenses?

> %if %{with bundled}
> Provides:   bundled(golang(github.com/ansible/receptor) = 1.4.1
> Provides:   bundled(golang(github.com/creack/pty) = 1.1.18
> Provides:   bundled(golang(github.com/davecgh/go-spew) = 1.1.1
> Provides:   bundled(golang(github.com/emicklei/go-restful/v3) = 3.10.2
> Provides:   bundled(golang(github.com/fortytw2/leaktest) = 1.3.0
> Provides:   bundled(golang(github.com/fsnotify/fsnotify) = 1.6.0
> Provides:   bundled(golang(github.com/ghjm/cmdline) = 0.1.2
> Provides:   bundled(golang(github.com/go-logr/logr) = 1.2.4
> Provides:   bundled(golang(github.com/go-openapi/jsonpointer) = 0.19.6
> Provides:   bundled(golang(github.com/go-openapi/jsonreference) = 0.20.2
> Provides:   bundled(golang(github.com/go-openapi/swag) = 0.22.3
> Provides:   bundled(golang(github.com/go-task/slim-sprig) = 
> 0.0.0-20230315git52ccab3
> Provides:   bundled(golang(github.com/gogo/protobuf) = 1.3.2
> Provides:   bundled(golang(github.com/golang-jwt/jwt/v4) = 4.5.0
> Provides:   bundled(golang(github.com/golang/mock) = 1.6.0
> Provides:   bundled(golang(github.com/golang/protobuf) = 1.5.3
> Provides:   bundled(golang(github.com/google/gnostic) = 0.6.9
> Provides:   bundled(golang(github.com/google/go-cmp) = 0.5.9
> Provides:   bundled(golang(github.com/google/gofuzz) = 1.2.0
> Provides:   bundled(golang(github.com/google/pprof) = 
> 0.0.0-20230502git255e3b9
> Provides:   bundled(golang(github.com/google/shlex) = 
> 0.0.0-20191202gite7afc7f
> Provides:   bundled(golang(github.com/google/uuid) = 1.3.0
> Provides:   bundled(golang(github.com/gorilla/websocket) = 1.5.0
> Provides:   bundled(golang(github.com/imdario/mergo) = 0.3.15
> Provides:   bundled(golang(github.com/josharian/intern) = 1.0.0
> Provides:   bundled(golang(github.com/json-iterator/go) = 1.1.12
> Provides:   bundled(golang(github.com/jupp0r/go-priority-queue) = 
> 0.0.0-20160601gitab10738
> Provides:   bundled(golang(github.com/mailru/easyjson) = 0.7.7
> Provides:   bundled(golang(github.com/minio/highwayhash) = 1.0.2
> Provides:   bundled(golang(github.com/moby/spdystream) = 0.2.0
> Provides:   bundled(golang(github.com/modern-go/concurrent) = 
> 0.0.0-20180306gitbacd9c7
> Provides:   bundled(golang(github.com/modern-go/reflect2) = 1.0.2
> Provides:   bundled(golang(github.com/munnerz/goautoneg) = 
> 0.0.0-20191010gita7dc8b6
> Provides:   bundled(golang(github.com/onsi/ginkgo/v2) = 2.9.4
> Provides:   bundled(golang(github.com/pbnjay/memory) = 
> 0.0.0-20210728git7b4eea6
> Provides:   bundled(golang(github.com/pmezard/go-difflib) = 1.0.0
> Provides:   bundled(golang(github.com/prep/socketpair) = 
> 0.0.0-20171228gitc2c6a7f
> Provides:   bundled(golang(github.com/quic-go/qtls-go1-19) = 0.3.2
> Provides:   bundled(golang(github.com/quic-go/qtls-go1-20) = 0.2.2
> Provides:   bundled(golang(github.com/quic-go/quic-go) = 0.34.0
> Provides:   bundled(golang(github.com/rogpeppe/go-internal) = 1.10.0
> Provides:   bundled(golang(github.com/songgao/water) = 
> 0.0.0-20200317git2b4b6d7
> Provides:   bundled(golang(github.com/spf13/pflag) = 1.0.5
> Provides:   bundled(golang(github.com/stretchr/testify) = 1.8.1
> Provides:   bundled(golang(github.com/vishvananda/netlink) = 1.1.0
> Provides:   bundled(golang(github.com/vishvananda/netns) = 0.0.4
> Provides:   bundled(golang(golang.org/x/crypto) = 0.8.0
> Provides:   bundled(golang(golang.org/x/exp) = 0.0.0-20230425git47ecfdc
> Provides:   bundled(golang(golang.org/x/mod) = 0.10.0
> Provides:   bundled(golang(golang.org/x/net) = 0.9.0
> Provides:   

Re: RPM packaging help

2023-08-13 Thread Brad Smith
On Sun, Aug 13, 2023 at 9:12 AM Robert-André Mauchin  wrote:
>

>
> I don't have an ETA on the K8S situation.
>

Please let me know if there is anything that can be done with the
kubernetes rpms to help.

Best regards

Brad
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-13 Thread Andrew Heath
Robert,
Thanks again for your help!

On Sun, Aug 13, 2023, 12:12 PM Robert-André Mauchin 
wrote:

> On 8/13/23 17:30, Andrew Heath wrote:
> > Robert,
> > Thank you,  this is very helpful, so I guess the questions I have is if
> I'm reading
> > your email correctly
> >
> > 1. Is for now we need to deal with the vendor directory, but should
> start working to
> > packaging some of the go-lang dependencies as rpms?
> >
>
> You should make review requests with the SPEC I provided in my
> Fedorapeople space.
>
> I don't have an ETA on the K8S situation.
>
> > 2. With the bundled vendor directory we have a "functional" build of the
> rpm that should
> > work in theory?
> >
>
> Currently the executable would work cause Golang is statically built. The
> library is
> disabled cause it probably wouldn't work without unbundling for other
> projects using it.
>
> Note that I haven't tested none of the executable, I don't know if it
> needs special config
> or anything else.
>
> Cheers,
>
> Robert-André
> ___
> devel mailing list -- devel@lists.fedoraproject.org
> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
> Fedora Code of Conduct:
> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives:
> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
> Do not reply to spam, report it:
> https://pagure.io/fedora-infrastructure/new_issue
>
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-13 Thread Robert-André Mauchin

On 8/13/23 17:30, Andrew Heath wrote:

Robert,
Thank you,  this is very helpful, so I guess the questions I have is if I'm reading 
your email correctly


1. Is for now we need to deal with the vendor directory, but should start working to 
packaging some of the go-lang dependencies as rpms?




You should make review requests with the SPEC I provided in my Fedorapeople 
space.

I don't have an ETA on the K8S situation.

2. With the bundled vendor directory we have a "functional" build of the rpm that should 
work in theory?




Currently the executable would work cause Golang is statically built. The library is 
disabled cause it probably wouldn't work without unbundling for other projects using it.


Note that I haven't tested none of the executable, I don't know if it needs special config 
or anything else.


Cheers,

Robert-André
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-13 Thread Andrew Heath
Robert,
Thank you,  this is very helpful, so I guess the questions I have is if I'm
reading your email correctly

1. Is for now we need to deal with the vendor directory, but should start
working to packaging some of the go-lang dependencies as rpms?

2. With the bundled vendor directory we have a "functional" build of the
rpm that should work in theory?


On Sun, Aug 13, 2023, 5:24 AM Robert-André Mauchin 
wrote:

> On 8/10/23 15:43, Andrew Heath wrote:
> > All,
> > My name is Andrew, and I have been working with the Fedora Infra team
> and we are trying to
> > create some RPMs for some projects that we are working on, one of the
> RPMs we need to create
> > is for the Ansible receptor[1 ]. I
> have a copy of the
> > spec file from downstream Red Hat that gives some guidance but where its
> a mix of python and
> > go-lang I was wondering if I could have some guidance from more
> experienced packers on how
> > to package up the application correctly so that we can get the package
> in use for the Fedora
> > Infra.
> >
> > Links:
> > [1]: https://github.com/ansible/receptor <
> https://github.com/ansible/receptor>
> >
> > --
> > Sincerely,
> > Andrew Heath
> > aheath1...@gmail.com 
> >
>
> Ok, let's roll, you will end up with a Frankstein SPEC, be warned. Here is
> the process:
>
> Let's start with:
>
> $ go2rpm github.com/ansible/receptor --name receptor
>
>
> We clean up a bit the description, the docs and we got:
>
> # receptor.spec
> # Generated by go2rpm 1.9.0
> %bcond_without check
>
> # https://github.com/ansible/receptor
> %global goipath github.com/ansible/receptor
> Version:1.4.1
>
> %gometa -f
>
> %global goname receptor
>
> %global common_description %{expand:
> Receptor is an overlay network intended to ease the distribution of work
> across
> a large and dispersed collection of workers. Receptor nodes establish
> peer-to-peer connections with each other via existing networks. Once
> connected,
> the Receptor mesh provides datagram (UDP-like) and stream (TCP-like)
> capabilities to applications, as well as robust unit-of-work handling with
> resiliency against transient network failures.
>
> See the readthedocs page for Receptor at:
>
> https://receptor.readthedocs.io/en/latest}
>
> %global golicenses  LICENSE.md
> %global godocs  docs tools README.md
>
> Name:   %{goname}
> Release:%autorelease
> Summary:Multi-service relayer with remote execution and
> orchestration capabilities
>
> License:Apache-2.0
> URL:%{gourl}
> Source: %{gosource}
>
> %description %{common_description}
>
> %gopkg
>
> %prep
> %goprep
> %autopatch -p1
> mv receptor-python-worker/README.md README-receptor-python-worker.md
> mv receptorctl/README.md README-receptorctl.md
>
>
> %generate_buildrequires
> %go_generate_buildrequires
>
> %build
> %gobuild -o %{gobuilddir}/bin/receptor %{goipath}/cmd/receptor-cl
>
> %install
> %gopkginstall
> install -m 0755 -vd %{buildroot}%{_bindir}
> install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/
>
> %if %{with check}
> %check
> %gocheck
> %endif
>
> %files
> %license LICENSE.md
> %doc docs tools README.md
> %{_bindir}/receptor
>
> %gopkgfiles
>
> %changelog
> %autochangelog
>
>
> Let's do a mockbuild on this and see what deps are needed for the Go
> binary:
>
> $ spectool -g *.spec
> $ fedpkg --release f40 mockbuild --mock-config
> /home/bob/packaging/mock2.cfg -N
>
>
> Ok I had to make a small detour and send a patch upstream to work with Go
> 1.21 with is in F40:
>
> # https://github.com/ansible/receptor/pull/816
> Patch:  0001-Bump-quic-go-to-0.37.4.patch
>
>
> Ok now we have our missing dependencies:
>
> No matching package to install: 'golang(github.com/ghjm/cmdline)'
> No matching package to install: 'golang(
> github.com/jupp0r/go-priority-queue)'
> No matching package to install: 'golang(github.com/pbnjay/memory)'
> No matching package to install: 'golang(github.com/prep/socketpair)'
>
> rpmname.py github.com/ghjm/cmdline \
> github.com/jupp0r/go-priority-queue \
> github.com/pbnjay/memory \
> github.com/prep/socketpair
>
> We thus need to package these new packages:
>
> golang-github-ghjm-cmdline
> golang-github-jupp0r-priority-queue
> golang-github-pbnjay-memory
> golang-github-prep-socketpair
>
> You need to run go2rpm for each package. I've build them, there is no
> dependency hell, they
> scratch build ok against Rawhide.
>
> So now, we hit a snag during the build:
>
> # github.com/ansible/receptor/pkg/workceptor
> _build/src/github.com/ansible/receptor/pkg/workceptor/kubernetes.go:682:16:
>
> exec.StreamWithContext undefined (type "
> k8s.io/client-go/tools/remotecommand".Executor has
> no field or method StreamWithContext)
>
>
> Our Kubernetes in Fedora is outdated. So we'll need to update it before
> being able to build
> receptor.
>
> For now 

Re: RPM packaging help

2023-08-13 Thread Robert-André Mauchin

On 8/10/23 15:43, Andrew Heath wrote:

All,
My name is Andrew, and I have been working with the Fedora Infra team and we are trying to 
create some RPMs for some projects that we are working on, one of the RPMs we need to create 
is for the Ansible receptor[1 ]. I have a copy of the 
spec file from downstream Red Hat that gives some guidance but where its a mix of python and 
go-lang I was wondering if I could have some guidance from more experienced packers on how 
to package up the application correctly so that we can get the package in use for the Fedora 
Infra.


Links:
[1]: https://github.com/ansible/receptor 

--
Sincerely,
Andrew Heath
aheath1...@gmail.com 



Ok, let's roll, you will end up with a Frankstein SPEC, be warned. Here is the 
process:

Let's start with:

$ go2rpm github.com/ansible/receptor --name receptor


We clean up a bit the description, the docs and we got:

# receptor.spec
# Generated by go2rpm 1.9.0
%bcond_without check

# https://github.com/ansible/receptor
%global goipath github.com/ansible/receptor
Version:1.4.1

%gometa -f

%global goname receptor

%global common_description %{expand:
Receptor is an overlay network intended to ease the distribution of work across
a large and dispersed collection of workers. Receptor nodes establish
peer-to-peer connections with each other via existing networks. Once connected,
the Receptor mesh provides datagram (UDP-like) and stream (TCP-like)
capabilities to applications, as well as robust unit-of-work handling with
resiliency against transient network failures.

See the readthedocs page for Receptor at:

https://receptor.readthedocs.io/en/latest}

%global golicenses  LICENSE.md
%global godocs  docs tools README.md

Name:   %{goname}
Release:%autorelease
Summary:Multi-service relayer with remote execution and orchestration 
capabilities

License:Apache-2.0
URL:%{gourl}
Source: %{gosource}

%description %{common_description}

%gopkg

%prep
%goprep
%autopatch -p1
mv receptor-python-worker/README.md README-receptor-python-worker.md
mv receptorctl/README.md README-receptorctl.md


%generate_buildrequires
%go_generate_buildrequires

%build
%gobuild -o %{gobuilddir}/bin/receptor %{goipath}/cmd/receptor-cl

%install
%gopkginstall
install -m 0755 -vd %{buildroot}%{_bindir}
install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/

%if %{with check}
%check
%gocheck
%endif

%files
%license LICENSE.md
%doc docs tools README.md
%{_bindir}/receptor

%gopkgfiles

%changelog
%autochangelog


Let's do a mockbuild on this and see what deps are needed for the Go binary:

$ spectool -g *.spec
$ fedpkg --release f40 mockbuild --mock-config /home/bob/packaging/mock2.cfg -N


Ok I had to make a small detour and send a patch upstream to work with Go 1.21 
with is in F40:

# https://github.com/ansible/receptor/pull/816
Patch:  0001-Bump-quic-go-to-0.37.4.patch


Ok now we have our missing dependencies:

No matching package to install: 'golang(github.com/ghjm/cmdline)'
No matching package to install: 'golang(github.com/jupp0r/go-priority-queue)'
No matching package to install: 'golang(github.com/pbnjay/memory)'
No matching package to install: 'golang(github.com/prep/socketpair)'

rpmname.py github.com/ghjm/cmdline \
   github.com/jupp0r/go-priority-queue \
   github.com/pbnjay/memory \
   github.com/prep/socketpair

We thus need to package these new packages:

golang-github-ghjm-cmdline
golang-github-jupp0r-priority-queue
golang-github-pbnjay-memory
golang-github-prep-socketpair

You need to run go2rpm for each package. I've build them, there is no dependency hell, they 
scratch build ok against Rawhide.


So now, we hit a snag during the build:

# github.com/ansible/receptor/pkg/workceptor
_build/src/github.com/ansible/receptor/pkg/workceptor/kubernetes.go:682:16: 
exec.StreamWithContext undefined (type "k8s.io/client-go/tools/remotecommand".Executor has 
no field or method StreamWithContext)



Our Kubernetes in Fedora is outdated. So we'll need to update it before being able to build 
receptor.


For now we'll take the bundled route, we add a bundled condition, add an archive with 
vendored deps and stuff.


# Generated by go2rpm 1.9.0
%bcond_without check
%bcond_without bundled
%if %{defined rhel}
%bcond_without bundled
%endif

# https://github.com/ansible/receptor
%global goipath github.com/ansible/receptor
Version:1.4.1

%gometa -f

%global goname receptor

%global common_description %{expand:
Receptor is an overlay network intended to ease the distribution of work across
a large and dispersed collection of workers. Receptor nodes establish
peer-to-peer connections with each other via existing networks. Once connected,
the Receptor mesh provides datagram (UDP-like) and stream (TCP-like)

Re: RPM packaging help

2023-08-10 Thread Maxwell G
Hi Robert-André and Andrew,

On Fri Aug 11, 2023 at 06:47 +0200, Robert-André Mauchin wrote:
> On 8/10/23 15:43, Andrew Heath wrote:
> > All,
> > My name is Andrew, and I have been working with the Fedora Infra team and 
> > we are trying to 
> > create some RPMs for some projects that we are working on, one of the RPMs 
> > we need to create 
> > is for the Ansible receptor[1 ]. I 
> > have a copy of the 
> > spec file from downstream Red Hat that gives some guidance but where its a 
> > mix of python and 
> > go-lang I was wondering if I could have some guidance from more experienced 
> > packers on how 
> > to package up the application correctly so that we can get the package in 
> > use for the Fedora 
> > Infra.
> > 
> > Links:
> > [1]: https://github.com/ansible/receptor 
> > 
> > 
> > -- 
> > Sincerely,
> > Andrew Heath
> > aheath1...@gmail.com 
>
> Hello,
>
> Is the final package for RHEL or Fedora? There are different guidelines 
> regarding bundling I 
> believe.

I would follow the Go Packaging Guidelines and use unbundled deps if
possible. If there are too many unpackaged dependencies or you run into
broken packages or other issues, I'd go with vendoring. I and others at
Flock discussed using more vendoring for Go packages given the
unmaintainable large stack of Go library packages and the outdated
and/or broken state of many of them.

> The first issue I see is that there are two separate Python project in two 
> subdirectories. 
> Not sure how to handle that.
>
> Could you share the dowstream?

https://fedorapeople.org/~gotmax23/receptor-1.4.1-1.el9ap.src/

This specfile does not use the modern Pyproject Python macros nor the
modern Go macros. It doesn't have an SPDX license identifier either.

The way it does vendoring is a problem, as it provides no instructions
to regenerate the archive with `go mod vendor`.
I believe Yaakov Selkowitz wrote a good script for this (I remember
asking him to provide one when reviewing a "vendor dependencies for X"
PR for an ELN package), but I can't seem to find it :(.
The vendor archive should contain %{version} in its name so that it's
tied to the main archive.
The specfile should have `%license vendor/modules.txt` so that the
go_mod_vendor generator can create the appropriate `bundled()` Provides.
The License field needs to account for the licenses of the bundled
libraries.

Overall, this is a complicated project and perhaps not the best for
someone new to RPM packaging. I grimaced when I first saw Go and Python
mixed together in the repository. I would suggest starting with
something like ansible-builder and ansible-navigator or other more
straightforward parts of the AWX/AAP stack and move on to this.
That said, I'm happy to answer any potential questions as best as I can.


-- 
Best,

Maxwell G (@gotmax23)
Pronouns: He/They
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-10 Thread Robert-André Mauchin

On 8/10/23 15:43, Andrew Heath wrote:

All,
My name is Andrew, and I have been working with the Fedora Infra team and we are trying to 
create some RPMs for some projects that we are working on, one of the RPMs we need to create 
is for the Ansible receptor[1 ]. I have a copy of the 
spec file from downstream Red Hat that gives some guidance but where its a mix of python and 
go-lang I was wondering if I could have some guidance from more experienced packers on how 
to package up the application correctly so that we can get the package in use for the Fedora 
Infra.


Links:
[1]: https://github.com/ansible/receptor 

--
Sincerely,
Andrew Heath
aheath1...@gmail.com 


Hello,

Is the final package for RHEL or Fedora? There are different guidelines regarding bundling I 
believe.


The first issue I see is that there are two separate Python project in two subdirectories. 
Not sure how to handle that.


Could you share the dowstream?

I will look at it tonight/this week-end.

Robert-André
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-10 Thread Adam Williamson
On Thu, 2023-08-10 at 09:43 -0400, Andrew Heath wrote:
> All,
> My name is Andrew, and I have been working with the Fedora Infra team and
> we are trying to create some RPMs for some projects that we are working on,
> one of the RPMs we need to create is for the Ansible receptor[1
> ]. I have a copy of the spec file from
> downstream Red Hat that gives some guidance but where its a mix of python
> and go-lang I was wondering if I could have some guidance from more
> experienced packers on how to package up the application correctly so that
> we can get the package in use for the Fedora Infra.

Well, it seems like it's mostly a Go library (or some Go libraries),
with a Python CLI and associated Python library.

I would think you can package it mostly following the Go guidelines,
but also at appropriate points in the spec drop into the receptorctl
subdirectory and use the modern Python macros - see the Python sample
spec,
https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_example_spec_file
- to install the Python bits (I think the %pyproject stuff should work
for this as it has what looks like a valid pyproject.toml ).

I'd then put the receptorctl bits - the Python lib and the CLI command
- into a subpackage that requires the main package(s), since it seems
to be essentially an optional bit...
-- 
Adam Williamson (he/him/his)
Fedora QA
Fedora Chat: @adamwill:fedora.im | Mastodon: @ad...@fosstodon.org
https://www.happyassassin.net



___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue


Re: RPM packaging help

2023-08-10 Thread Priscila Gutierres
Hello Andrew,

I have some experience with golang and python packaging, but working on
RHEL, not Fedora.
But we can walk through together to decipher  it.

Priscila.

On Thu, Aug 10, 2023 at 10:43 AM Andrew Heath  wrote:

> All,
> My name is Andrew, and I have been working with the Fedora Infra team and
> we are trying to create some RPMs for some projects that we are working on,
> one of the RPMs we need to create is for the Ansible receptor[1
> ]. I have a copy of the spec file
> from downstream Red Hat that gives some guidance but where its a mix of
> python and go-lang I was wondering if I could have some guidance from more
> experienced packers on how to package up the application correctly so that
> we can get the package in use for the Fedora Infra.
>
> Links:
> [1]: https://github.com/ansible/receptor
>
> --
> Sincerely,
> Andrew Heath
> aheath1...@gmail.com
> ___
> devel mailing list -- devel@lists.fedoraproject.org
> To unsubscribe send an email to devel-le...@lists.fedoraproject.org
> Fedora Code of Conduct:
> https://docs.fedoraproject.org/en-US/project/code-of-conduct/
> List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
> List Archives:
> https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
> Do not reply to spam, report it:
> https://pagure.io/fedora-infrastructure/new_issue
>
___
devel mailing list -- devel@lists.fedoraproject.org
To unsubscribe send an email to devel-le...@lists.fedoraproject.org
Fedora Code of Conduct: 
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: 
https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org
Do not reply to spam, report it: 
https://pagure.io/fedora-infrastructure/new_issue