nice-florist-55958
11/23/2021, 2:43 PMfast-nail-55400
11/23/2021, 3:23 PMmain
method and then put:
if __name__ == "__main__":
main()
at the bottom of the file. If you use this pattern, then your PEX entry script can simply import that main
method and call it directly.nice-florist-55958
11/23/2021, 4:02 PMfast-nail-55400
11/23/2021, 4:04 PMnice-florist-55958
11/23/2021, 4:13 PMenough-analyst-54434
11/23/2021, 4:25 PMcat
and it will work. Pants doesn't currently give you a way to build one though.nice-florist-55958
11/23/2021, 4:31 PMenough-analyst-54434
11/23/2021, 4:35 PMpackage
goal in your repo.pex_binary
if variance is needed.fast-nail-55400
11/23/2021, 4:52 PMI guess the way to think of it, when a host restarts it should run some setup script to make things like Python accessible. But we can’t make that assumption, so want to run a shell script first.Are your hosts using a config management solution like chef or puppet?