Hi, I was setting up Airbyte on AWS  by following ...
# announcements
a
Hi, I was setting up Airbyte on AWS  by following the same instructions described here: https://docs.airbyte.io/deploying-airbyte/on-aws-ec2 But I wanted to set up on different port than default 8000. In the doc its mentioned to update API_URL in env file - So can you please help me what exactly needs to be added in docker-compose.yaml file? webapp:     image: airbyte/webapp:${VERSION}     container_name: airbyte-webapp     ports:       - 5000:80     environment:       - AIRBYTE_ROLE=${AIRBYTE_ROLE:-}       - AIRBYTE_VERSION=${VERSION}       - API_URL=${API_URL:-} I did tried to change ports section in webapp ports but when i tried to run UI on browser. Its opening Airbyte but giving error-
1
d
Hi, the urls are specified in the
.env
file. Changing the right variable there should be sufficient
May I ask what are you trying to do by using a different port?
a
port 8000 is already in use on AWS EC2 instance, so i am trying to start Airbyte on different port
Do you mind specifying which env file and variables? Sorry I am completely new to Airbyte
c
Airbyte uses two ports: • the 8000 port is the Webapp port (for the webpage) • the 8001 port is the API port (for contacting the server) you only need to change the 8000 right?
a
I need to change both
As the other both of the ports are being used by some other app on server
c
I am guessing you need to change the docker-compose file as follow:
this is on AWS EC2 right? So you would still need to go through SSH tunnel setup: https://docs.airbyte.io/deploying-airbyte/on-aws-ec2#connect-to-airbyte
Copy code
# In your workstation terminal
ssh -i $SSH_KEY -L 5000:localhost:5000 -L 5001:localhost:5001 -N -f ec2-user@$INSTANCE_IP
Looking at
.env
file, you see examples of
API_URL
and
WEBAPP_URL
so i think your
API_URL
should be
<http://localhost:5001/api/v1/>
a
I have already tried changing both ports but getting cannot reach server error-
image.png
And api url is not working-
<http://localhost:5001/api/v1/>
c
in your browser, you can inspect and look at network logs and see if there are error messages?
Screenshot 2021-04-26 at 12.40.43.png
a
Getting these errors-
image.png
a
yes
c
can you take a look at your server logs?
docker-compose logs server
and check that things are running:
docker ps
a
There is no error in logs but it is still printing now ready at 8000 port even after changing port to 5000
c
(yes the message doesn’t get updated)
a
image.png
oh ok
image.png
c
I believe your port bindings for your server are wrong
it should say:
0.0.0.0:5001->8001/tcp, 8000/tcp
a
Thanks @Chris (deprecated profile)! I made incorrect binding for API port as 5001: 5001; changed it to 5001:8001. Its working now.
🎉 1