Skip to content

Commit

Permalink
Merge pull request #3 from simonjj/change-port-and-readme
Browse files Browse the repository at this point in the history
Change port from 3500 to 8080
  • Loading branch information
simonjj authored Jan 24, 2024
2 parents 9e2eaf0 + ff5cfc2 commit 67010c2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 13 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ This is the companion repository for the [Azure Container Apps code-to-cloud qui

This backend Album API sample is available in other languages:

| [C#](https://github.com/azure-samples/containerapps-albumapi-csharp) | [Go](https://github.com/azure-samples/containerapps-albumapi-go) | [JavaScript](https://github.com/azure-samples/containerapps-albumapi-javascript) |
| -------------------------------------------------------------------- | ---------------------------------------------------------------- | ------------------------------------------------------------------------ |
| [C#](https://github.com/azure-samples/containerapps-albumapi-csharp) | [Go](https://github.com/azure-samples/containerapps-albumapi-go) | [JavaScript](https://github.com/azure-samples/containerapps-albumapi-javascript) | [Java](https://github.com/azure-samples/containerapps-albumapi-java) |
| -------------------------------------------------------------------- | ---------------------------------------------------------------- | ------------------------------------------------------------------------ | ---------------------------------------------------------------- |
13 changes: 3 additions & 10 deletions src/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,7 @@

FROM python:3.11

WORKDIR /code

COPY requirements.txt .

RUN pip3 install -r requirements.txt

RUN pip3 install --no-cache-dir -r requirements.txt
COPY . .

EXPOSE 3500

ENTRYPOINT ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "3500"]
EXPOSE 8080
CMD ["uvicorn", "app.main:app", "--host", "0.0.0.0", "--port", "8080"]
2 changes: 1 addition & 1 deletion src/app/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ def __init__(self, id, title, artist, price, image_url):

@app.get("/")
def read_root():
return {"Azure Container Apps Python Sample API"}
return {"Access /albums to see the list of albums"}


@app.get("/albums")
Expand Down

0 comments on commit 67010c2

Please sign in to comment.