Questions tagged with Amazon Elastic Container Service

Content language: English

Sort by most recent

Browse through the questions and answers listed below or filter and sort to narrow down your results.

copilot fails with "templates/custom-resources/nlb-cert-validator.js: file does not exist" (on Macbook Pro M1)

I'm experimenting with AWS Copilot. I have an existing trivial nodejs project that has already been containerized with Docker. I'm trying to use it with AWS Copilot to get a feel for copilot. Note I am running this on a Macbook Pro M1, I wonder if this is an architecture issue or if that's a red herring... The `copilot init` process fails (after doing a lot successfully) with: ``` => [run 1/1] RUN yarn build 28.2s => exporting to image 5.1s => => exporting layers 5.1s => => writing image sha256:260f1aae6a9d11b023672a1f3753161d1d38afa118c483804f9ef79d0c4e52a1 0.0s => => naming to xxx.dkr.ecr.us-east-2.amazonaws.com/em-sandbox/em-nodejs-service-template 0.0s Use 'docker scan' to run Snyk tests against images to find vulnerabilities and learn how to fix them Login Succeeded Using default tag: latest The push refers to repository [xxx.dkr.ecr.us-east-2.amazonaws.com/em-sandbox/em-nodejs-service-template] 97b95ee3261b: Pushed 59618adc7d11: Pushed 4c3b5d9c5d94: Pushed 1c37a59f80eb: Pushed 099cd5535f68: Pushed bb2ebe54bcf0: Pushed cd2258b7ca68: Pushed fbf63a621b59: Pushed 994393dc58e7: Pushed latest: digest: sha256:2481df4d9803e63ddde3992a9224cda89e27365d859f627c962692436715e14a size: 2208 ✘ upload deploy resources for service em-nodejs-service-template: read custom resources for a "Load Balanced Web Service": read custom resource NLBCertValidatorFunction at path custom-resources/nlb-cert-validator.js: read template custom-resources/nlb-cert-validator.js: open templates/custom-resources/nlb-cert-validator.js: file does not exist ``` For what it's worth, here's how I answered the initial questions in `copilot init`. I did also ask for a test environment to be set up. ``` Application name: em-sandbox Workload type: Load Balanced Web Service Service name: em-nodejs-service-template Dockerfile: ./Dockerfile Port: 4000 Ok great, we'll set up a Load Balanced Web Service named em-nodejs-service-template in application em-sandbox listening on port 4000. ✔ Proposing infrastructure changes for stack em-sandbox-infrastructure-roles - Creating the infrastructure for stack em-sandbox-infrastructure-roles [create complete] [40.8s] - A StackSet admin role assumed by CloudFormation to manage regional stacks [create complete] [12.9s] - An IAM role assumed by the admin role to create ECR repositories, KMS keys, and S3 buckets [create complete] [14.3s] ✔ The directory copilot will hold service manifests for application em-sandbox. Note: Architecture type arm64 has been detected. We will set platform 'linux/x86_64' instead. If you'd rather build and run as architecture type arm64, please change the 'platform' field in your workload manifest to 'linux/arm64'. ✔ Wrote the manifest for service em-nodejs-service-template at copilot/em-nodejs-service-template/manifest.yml Your manifest contains configurations like your container size and port (:4000). - Update regional resources with stack set "em-sandbox-infrastructure" [succeeded] [0.0s] All right, you're all set for local development. Deploy: Yes ✔ Wrote the manifest for environment test at copilot/environments/test/manifest.yml ...etc... ```
1
answers
0
votes
20
views
asked a month ago

Docker Compose services to Fargate tasks/services

Hi Everyone. I am trying to set up ERPNext on AWS ECS(Fargate). I used [frappe_docker](https://github.com/frappe/frappe_docker/blob/main/docs/images-and-compose-files.md) to setup locally. I want to create containers in task definition of AWS ECS Fargate according to the services in yaml file. I have mentioned the content of yaml file below. I am stuck at - setting depends_on property while defining - defining volumes as defined in the YAML file. I have given the YAML file according to which I want to define tasks in AWS ECS. I am new to AWS services. Pardon me for any ambiguous information ```yaml name: frappe_docker services: backend: depends_on: configurator: condition: service_completed_successfully image: frappe/erpnext-worker:v14.2.2 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} - type: volume source: assets target: /home/frappe/frappe-bench/sites/assets read_only: true volume: {} configurator: command: - configure.py environment: DB_HOST: ***.rds.amazonaws.com DB_PORT: "3306" REDIS_CACHE: ***.cache.amazonaws.com:6379/0 REDIS_QUEUE: ***.cache.amazonaws.com:6379/1 REDIS_SOCKETIO: ***.cache.amazonaws.com:6379/2 SOCKETIO_PORT: "9000" image: frappe/erpnext-worker:v14.2.2 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} - type: volume source: assets target: /home/frappe/frappe-bench/sites/assets read_only: true volume: {} frontend: depends_on: backend: condition: service_started websocket: condition: service_started environment: BACKEND: backend:8000 FRAPPE_SITE_NAME_HEADER: $$host SOCKETIO: websocket:9000 UPSTREAM_REAL_IP_ADDRESS: 127.0.0.1 UPSTREAM_REAL_IP_HEADER: X-Forwarded-For UPSTREAM_REAL_IP_RECURSIVE: "off" image: frappe/erpnext-nginx:v14.2.2 networks: default: null volumes: - type: volume source: assets target: /usr/share/nginx/html/assets volume: {} - type: volume source: sites target: /usr/share/nginx/html/sites volume: {} queue-default: command: - bench - worker - --queue - default depends_on: configurator: condition: service_completed_successfully image: frappe/erpnext-worker:v14.2.2 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} - type: volume source: assets target: /home/frappe/frappe-bench/sites/assets read_only: true volume: {} queue-long: command: - bench - worker - --queue - long depends_on: configurator: condition: service_completed_successfully image: frappe/erpnext-worker:v14.2.2 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} - type: volume source: assets target: /home/frappe/frappe-bench/sites/assets read_only: true volume: {} queue-short: command: - bench - worker - --queue - short depends_on: configurator: condition: service_completed_successfully image: frappe/erpnext-worker:v14.2.2 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} - type: volume source: assets target: /home/frappe/frappe-bench/sites/assets read_only: true volume: {} scheduler: command: - bench - schedule depends_on: configurator: condition: service_completed_successfully image: frappe/erpnext-worker:v14.2.2 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} - type: volume source: assets target: /home/frappe/frappe-bench/sites/assets read_only: true volume: {} websocket: depends_on: configurator: condition: service_completed_successfully image: frappe/frappe-socketio:v14.10.0 networks: default: null volumes: - type: volume source: sites target: /home/frappe/frappe-bench/sites volume: {} networks: default: name: frappe_docker_default volumes: assets: name: frappe_docker_assets sites: name: frappe_docker_sites x-backend-defaults: depends_on: configurator: condition: service_completed_successfully image: frappe/frappe-worker:v14.10.0 volumes: - sites:/home/frappe/frappe-bench/sites - assets:/home/frappe/frappe-bench/sites/assets:ro x-depends-on-configurator: depends_on: configurator: condition: service_completed_successfully x-erpnext-backend-image: image: frappe/erpnext-worker:v14.2.2 ```
1
answers
0
votes
34
views
asked 2 months ago