# Possibility to execute Python code use local-exec in Terraform Cloud

**URL:** <https://discuss.hashicorp.com/t/possibility-to-execute-python-code-use-local-exec-in-terraform-cloud/55133>\
**Category:** HCP Terraform\
**Created:** [June 18, 2023, 6:31am UTC](https://discuss.hashicorp.com/t/possibility-to-execute-python-code-use-local-exec-in-terraform-cloud/55133 "2023-06-18T06:31:18Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Adithya\_Pathipaka](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/adithya_pathipaka/32/36198_2.png) [@Adithya\_Pathipaka](https://discuss.hashicorp.com/u/Adithya_Pathipaka)\
**Post date:** [June 18, 2023, 6:31am UTC](https://discuss.hashicorp.com/t/possibility-to-execute-python-code-use-local-exec-in-terraform-cloud/55133/1 "2023-06-18T06:31:18Z")

</div>

Hi All,  
Is it possible to execute python code in terraform cloud (free licence) using **local-exec** using **null-resource provider**? As I know terraform cloud uses a raw image of linux flavour with no packages other terraform and network and executes the terraform code. I have tried to install packages, but it didn’t work.

What are the possible options to achieve this?

PS: I am trying to build a serverless application with network connectivity on AWS. I need to pull IP’s once a server is been created and use them in other data/resource block. I already tried with data block, but it didn’t work.

Thanks & Regards,  
Adithya

---

<div class="post-metadata">

**Author:** ![maxb](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/maxb/32/26655_2.png) [@maxb](https://discuss.hashicorp.com/u/maxb)\
**Post date:** [June 18, 2023, 7:18am UTC](https://discuss.hashicorp.com/t/possibility-to-execute-python-code-use-local-exec-in-terraform-cloud/55133/2 "2023-06-18T07:18:15Z")

</div>

The official docs address this (and strongly discourage it):

[https://developer.hashicorp.com/terraform/cloud-docs/run/install-software#installing-additional-tools](https://developer.hashicorp.com/terraform/cloud-docs/run/install-software#installing-additional-tools)
