You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This project demonstrates both client-side component rendering and hydration with Angular, as well as server-side rendering with Node.js and Socket.IO for real-time communication. It also includes Docker configurations for easy deployment.
5
+
This sample demonstrates how to deploy a full-stack Angular and Node.js application with Defang. It uses Socket.IO for real-time communication. The Docker setup ensures the app can be easily built and deployed.
6
6
7
-
## NOTE
7
+
## Prerequisites
8
8
9
-
This sample showcases how you could deploy a full-stack application with Angular and Node.js using Defang. The Docker setup ensures the app can be easily built and deployed.
For development, we use two local containers, one for the frontend Angular service and one for the backend service in Express. It also uses Caddy as a web server for serving static files.
2. (Optional) If you are using [Defang BYOC](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html) authenticated with your AWS account
15
-
3. (Optional for local development) [Docker CLI](https://docs.docker.com/engine/install/)
18
+
To run the application locally, you can use the following command:
2. (Optional) If you are using [Defang BYOC](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html) make sure you have properly authenticated your AWS account
Deploy your application to the Defang Playground by opening up your terminal and typing:
42
+
```bash
43
+
defang compose up
44
+
```
45
+
46
+
### BYOC (AWS)
31
47
32
-
For development, we use two local containers, one for the frontend Angular service and one for the backend service in Express. It also uses Caddy as a web server for serving static files. To run the sample locally after cloning the repository, you can run on Docker by doing:
48
+
If you want to deploy to your own cloud account, you can use Defang BYOC:
33
49
34
-
1.`docker compose -f compose.dev.yaml up --build`
50
+
1.[Authenticate your AWS account](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html), and check that you have properly set your environment variables like `AWS_PROFILE`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, and `AWS_SECRET_ACCESS_KEY`.
51
+
2. Run in a terminal that has access to your AWS environment variables:
52
+
```bash
53
+
defang --provider=aws compose up
54
+
```
35
55
36
56
---
37
57
@@ -41,4 +61,4 @@ Short Description: A full-stack application using Angular for the frontend and N
This project is a simple task manager application using ASP.NET Core. We show case how to deploy it to both Defang and Docker for both prod and dev environments.
5
+
This sample project is a simple task manager application using ASP.NET Core for the backend and JavaScript for client-side component rendering.
6
6
7
-
## NOTE
7
+
It showcases how you could deploy a full-stack application with ASP.NET Core and JavaScript using Defang. The Docker setup ensures the app can be easily built and tested during development.
8
8
9
-
This sample showcases how you could deploy a full-stack application with ASP.NET Core and JavaScript using Defang. The Docker setup ensures the app can be easily built and tested during development.
2. (Optional) If you are using [Defang BYOC](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html) authenticated with your AWS account
2. (Optional) If you are using [Defang BYOC](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html) make sure you have properly authenticated your AWS account
For development, we use two local containers, one for the frontend service and one for the backend service in ASP.NET Core. It also uses Caddy as a web server for serving static files.
22
19
23
-
## A Step-by-Step Guide for deployment
20
+
To run the application locally, you can use the following command:
24
21
25
-
1. Open the terminal and type `defang login`
26
-
2. Type `defang compose up` in the CLI
27
-
3. Your app should be up and running with Defang in minutes!
22
+
```bash
23
+
docker compose -f compose.dev.yaml up --build
24
+
```
25
+
## Configuration
28
26
29
-
## Development
27
+
For this sample, you will not need to provide [configuration](https://docs.defang.io/docs/concepts/configuration).
28
+
29
+
If you wish to provide configuration, see below for an example of setting a configuration for a value named `API_KEY`.
Deploy your application to the Defang Playground by opening up your terminal and typing:
43
+
```bash
44
+
defang compose up
45
+
```
46
+
47
+
### BYOC (AWS)
30
48
31
-
For development, we use two local containers, one for the frontend service and one for the backend service in ASP.NET Core. It also uses Caddy as a web server for serving static files. To run the sample locally after cloning the repository, you can run on Docker by doing:
49
+
If you want to deploy to your own cloud account, you can use Defang BYOC:
32
50
33
-
`docker compose -f compose.dev.yaml up --build`
51
+
1.[Authenticate your AWS account](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html), and check that you have properly set your environment variables like `AWS_PROFILE`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, and `AWS_SECRET_ACCESS_KEY`.
52
+
2. Run in a terminal that has access to your AWS environment variables:
53
+
```bash
54
+
defang --provider=aws compose up
55
+
```
34
56
35
57
---
36
58
37
59
Title: C# & ASP.NET Core
38
60
39
-
Short Description: A task manager using ASP.NET Core containerized with Docker.
61
+
Short Description: A simple task manager application using C# and ASP.NET Core.
2. (Optional) If you are using [Defang BYOC](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html) authenticated with your AWS account
11
-
3. (Optional - for local development) [Docker CLI](https://docs.docker.com/engine/install/)
10
+
2. (Optional) If you are using [Defang BYOC](https://docs.defang.io/docs/concepts/defang-byoc) authenticate with your cloud provider account
11
+
3. (Optional for local development) [Docker CLI](https://docs.docker.com/engine/install/)
12
12
13
-
## Deploying
13
+
## Development
14
14
15
-
1. Run `defang login` if you are not yet logged in.
16
-
2. Run `defang compose up`.
17
-
3. Your app will be running within a few minutes.
15
+
To run the application locally, you can use the following command:
18
16
19
-
## Local Development
17
+
```bash
18
+
docker compose -f compose.dev.yaml up --build
19
+
```
20
20
21
-
1. Run `docker compose -f compose.dev.yaml up --build`
21
+
## Configuration
22
+
23
+
For this sample, you will not need to provide [configuration](https://docs.defang.io/docs/concepts/configuration).
24
+
25
+
If you wish to provide configuration, see below for an example of setting a configuration for a value named `API_KEY`.
Deploy your application to the Defang Playground by opening up your terminal and typing:
39
+
```bash
40
+
defang compose up
41
+
```
42
+
43
+
### BYOC (AWS)
44
+
45
+
If you want to deploy to your own cloud account, you can use Defang BYOC:
46
+
47
+
1.[Authenticate your AWS account](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html), and check that you have properly set your environment variables like `AWS_PROFILE`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, and `AWS_SECRET_ACCESS_KEY`.
48
+
2. Run in a terminal that has access to your AWS environment variables:
Deploy your application to the Defang Playground by opening up your terminal and typing:
41
+
```bash
42
+
defang compose up
43
+
```
44
+
45
+
### BYOC (AWS)
46
+
47
+
If you want to deploy to your own cloud account, you can use Defang BYOC:
24
48
25
-
1. Open the terminal and type defang login
26
-
2. Type `defang compose up` in the CLI.
27
-
3. Your app will be running within a few minutes.
49
+
1.[Authenticate your AWS account](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html), and check that you have properly set your environment variables like `AWS_PROFILE`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, and `AWS_SECRET_ACCESS_KEY`.
50
+
2. Run in a terminal that has access to your AWS environment variables:
This is a sample of a basic Flask TODO app. The items are stored in memory and are lost when the server is restarted, but it should give you a basic idea of how to get started with Flask on Defang. Note that alognside your .py file, include a requirements.txt so that the Dockerfile can install the necessary packages with pip.
5
+
This is a basic Flask to-do app that can be deployed with Defang. Note that alongside your `.py` file, include a `requirements.txt` so that the Dockerfile can install the necessary packages with pip.
6
6
7
-
### NOTE:
7
+
This project is intended to provide a basic understanding of how to get started with Flask on Defang. The items are stored in memory and are lost when the server is restarted. **It is not intended for production use**. If you need something production ready, you should use a managed database like Postgres or MySQL.
8
8
9
-
This sample is a simple Flask app that demonstrates how to create a TODO app using Flask. The items are stored in memory and are lost when the server is restarted. This sample is intended to provide a basic understanding of how to get started with Flask on Defang. **it is not intended for production use**. If you need something production ready, you should use a managed database like Postgres or MySQL.
2. (Optional) If you are using [Defang BYOC](https://docs.defang.io/docs/concepts/defang-byoc) authenticate with your cloud provider account
13
+
3. (Optional for local development) [Docker CLI](https://docs.docker.com/engine/install/)
12
14
13
-
1. A [Dockerfile](https://docs.docker.com/develop/develop-images/dockerfile_best-practices/).
14
-
2. A [compose file](https://docs.defang.io/docs/concepts/compose) to define and run multi-container Docker applications (this is how Defang identifies services to be deployed).
15
-
3. A [.dockerignore](https://docs.docker.com/build/building/context/#dockerignore-files) to ignore files that are not needed in the Docker image or will be generated during the build process.
15
+
## Development
16
16
17
-
## Prerequisite
17
+
To run the application locally, you can use the following command:
2. If you are using [Defang BYOC](https://docs.defang.io/docs/concepts/defang-byoc), make sure you have properly [authenticated your AWS account (optional)](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html)
19
+
```bash
20
+
docker compose up --build
21
+
```
22
+
23
+
## Configuration
24
+
25
+
For this sample, you will not need to provide [configuration](https://docs.defang.io/docs/concepts/configuration).
26
+
27
+
If you wish to provide configuration, see below for an example of setting a configuration for a value named `API_KEY`.
Deploy your application to the Defang Playground by opening up your terminal and typing:
41
+
```bash
42
+
defang compose up
43
+
```
21
44
22
-
##A Step-by-Step Guide
45
+
### BYOC (AWS)
23
46
24
-
1. Open the terminal and type `defang login`
25
-
2. Type `defang compose up` in the CLI
26
-
3. Your app should be up and running with Defang in minutes!
47
+
If you want to deploy to your own cloud account, you can use Defang BYOC:
27
48
28
-
## One click deployment
49
+
1.[Authenticate your AWS account](https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-configure.html), and check that you have properly set your environment variables like `AWS_PROFILE`, `AWS_REGION`, `AWS_ACCESS_KEY_ID`, and `AWS_SECRET_ACCESS_KEY`.
50
+
2. Run in a terminal that has access to your AWS environment variables:
0 commit comments