AWS Glue Setup Medium
AWS Glue Setup Medium
Open in app
10
Search
Get unlimited access to the best of Medium for less than $1/week. Become a member
Introduction
If you’re new to AWS Glue and you don’t want to spend a lot of money on each ETL
code you execute, or if you’re a developer who wants to check and confirm your ETL
script locally before pushing it to AWS Glue, you can do a local setup and don’t need
to pay for the GPU (Graphics processing unit).
$ docker ps
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 1/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
If the Docker is already installed on your system, you will see the output as above
image. If you don’t see the above output, head over to Docker Desktop: The #1
Containerization Tool for Developers | Docker and follow the normal installation
procedure.
Step 2: Pull AWS Glue Docker Image
Once Docker is installed properly, open a new terminal and execute the following
command to pull the AWS Glue Docker image:
Depending on the speed of your internet, it may take a while to pull the image.
Further head over to the IAM (Identity and Access Management) section and
select ‘Users’ in the AWS Access management console. Select the user profile or
create a new IAM user profile.
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 2/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
Now, you can select or Create an IAM user. In this case, I have created an IAM
user. Click on the Add permissions, and select the option Create an inline policy.
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 3/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
Select “Glue” as the service and select the “All Glue actions” check box.
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 4/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
Select Command Line Interface (CLI) as the key type in the next window.
In the Description tag value section, provide a name for the Access key.
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 5/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
Make a note of the Access key and Secret access key or you can download it as a
CSV file.
Open a new terminal and type “AWS Configure”. Make sure you have installed
AWS CLI and if not, visit Install or update the latest version of the AWS CLI —
AWS Command Line Interface and follow the installation procedure.
Paste the Access key and Secret Access key in the terminal. Enter the default
region, keep the output format as it is, and click Enter.
1. If you do not wish to use AWS services, then execute the below command.
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 6/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
2. If you are running from a Windows terminal and want to integrate AWS services,
run the following command.
3. If you are running from a Linux/Mac Machine and want to integrate AWS services,
run the following command.
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 7/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
2. Click on the New drop-down and select Python3 to create a Jupyter notebook.
3. Paste and run the below code in the newly opened notebook to make sure that the
setup is working as expected.
sc = SparkContext.getOrCreate()
glueContext = GlueContext(sc)
spark = glueContext.spark_session
4. Run the code by pressing the Shift + Enter keys and if everything is working as
expected then the Jupyter notebook will run the code without throwing any error.
Conclusion
Setting up AWS Glue locally can be a great way to develop and test your data
processing jobs before deploying them to the cloud. However, it is important to keep
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 8/16
4/23/25, 9:49 PM Amazon Glue Local Setup — Test ETL Scripts Locally | by Muhammed Musthafa Shahal V | Impelsys | Medium
Follow
Published in Impelsys
30 Followers · Last published Apr 3, 2025
Impelsys is a global leader in delivering impactful, engaging & adaptable online learning solutions for global
publishers, education providers, & enterprises.
Edit profile
No responses yet
https://medium.com/impelsys/amazon-glue-local-setup-test-etl-scripts-locally-a0df8ee50858 9/16