mysql: build: ./mysql volumes: - ./mysql/startup:/docker-entrypoint-initdb.d volumes_from: - volumes_data ports: - "3309:3306" environment: MYSQL_ROOT_PASSWORD: 1234
However to run php artisan from workspace container I need .env to specify port 3306:
DB_HOST=mysql DB_DATABASE=local_a DB_USERNAME=root DB_PASSWORD=1234 DB_PORT=3306
I guess this is because I am connecting container to container, however maybe this will help someone.
Docker
https://github.com/FabrizioCafolla/microservice-lumen/wiki
https://www.poweredlocal.com.au/
php redis osx => may be manual build/install
https://stackoverflow.com/questions/50456780/run-mysql-on-port-3307-using-docker-compose
https://github.com/guillaumebriday/laravel-blog/blob/master/docker-compose.yml
https://medium.com/@shakyShane/laravel-docker-part-1-setup-for-development-e3daaefaf3c
Authen header bearer
http://self-issued.info/docs/draft-ietf-oauth-v2-bearer.html#authz-header
Ubuntu VPS work without header Authen, OSX seem need it => still not work => jwt:secret clear/reset secret to fix 'Token invalid'
https://blog.pusher.com/laravel-jwt/
https://blog.valiantys.com/en/dev-tools-en/devops-made-easy-with-bamboo/
https://blog.valiantys.com/en/expert-tips/deploying-docker-containers-aws/
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/Welcome.html
http://blog.totalcloud.io/ecs-vs-eks-vs-fargate-good-bad-ugly/
Some image for AWS
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html
https://console.aws.amazon.com/ecs/home?region=us-east-1#/firstRun
Docker ECS guide (dupli)
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/Welcome.html
membership$ ecs-cli up –keypair ~/.ssh/id_rsa_ecs.pub -instance-role ecsTaskExecutionRole –size 1 –instance-type t2.medium –port 8083
WARN[0000] You will not be able to SSH into your EC2 instances without a key pair.
INFO[0000] Using recommended Amazon Linux 2 AMI with ECS Agent 1.22.0 and Docker version 18.06.1-ce
INFO[0000] Created cluster cluster=primexdemo9 region=ap-southeast-1
INFO[0000] Waiting for your cluster resources to be created...
INFO[0000] Cloudformation stack status stackStatus=CREATE_IN_PROGRESS
INFO[0060] Cloudformation stack status stackStatus=CREATE_IN_PROGRESS
INFO[0120] Cloudformation stack status stackStatus=CREATE_IN_PROGRESS
VPC created: vpc-0b38e0efd75d1c4b7
Security Group created: sg-061bdb8ccc6c72671
Subnet created: subnet-0f07c528e9d6fe1f6
Subnet created: subnet-0aa9ba47908c511ed
aws ecs list-clusters
aws ecs delete-cluster --cluster="arn:aws:ecs:ap-southeast-1:861481479208:cluster/primexdemo7"
However to run php artisan from workspace container I need .env to specify port 3306:
DB_HOST=mysql DB_DATABASE=local_a DB_USERNAME=root DB_PASSWORD=1234 DB_PORT=3306
I guess this is because I am connecting container to container, however maybe this will help someone.
Docker
https://github.com/FabrizioCafolla/microservice-lumen/wiki
https://www.poweredlocal.com.au/
php redis osx => may be manual build/install
https://stackoverflow.com/questions/50456780/run-mysql-on-port-3307-using-docker-compose
https://github.com/guillaumebriday/laravel-blog/blob/master/docker-compose.yml
https://medium.com/@shakyShane/laravel-docker-part-1-setup-for-development-e3daaefaf3c
Authen header bearer
http://self-issued.info/docs/draft-ietf-oauth-v2-bearer.html#authz-header
Ubuntu VPS work without header Authen, OSX seem need it => still not work => jwt:secret clear/reset secret to fix 'Token invalid'
https://blog.pusher.com/laravel-jwt/
https://blog.valiantys.com/en/dev-tools-en/devops-made-easy-with-bamboo/
https://blog.valiantys.com/en/expert-tips/deploying-docker-containers-aws/
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/Welcome.html
http://blog.totalcloud.io/ecs-vs-eks-vs-fargate-good-bad-ugly/
Some image for AWS
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-continueupdaterollback.html
https://console.aws.amazon.com/ecs/home?region=us-east-1#/firstRun
Docker ECS guide (dupli)
https://docs.aws.amazon.com/AmazonECS/latest/developerguide/Welcome.html
membership$ ecs-cli up –keypair ~/.ssh/id_rsa_ecs.pub -instance-role ecsTaskExecutionRole –size 1 –instance-type t2.medium –port 8083
WARN[0000] You will not be able to SSH into your EC2 instances without a key pair.
INFO[0000] Using recommended Amazon Linux 2 AMI with ECS Agent 1.22.0 and Docker version 18.06.1-ce
INFO[0000] Created cluster cluster=primexdemo9 region=ap-southeast-1
INFO[0000] Waiting for your cluster resources to be created...
INFO[0000] Cloudformation stack status stackStatus=CREATE_IN_PROGRESS
INFO[0060] Cloudformation stack status stackStatus=CREATE_IN_PROGRESS
INFO[0120] Cloudformation stack status stackStatus=CREATE_IN_PROGRESS
VPC created: vpc-0b38e0efd75d1c4b7
Security Group created: sg-061bdb8ccc6c72671
Subnet created: subnet-0f07c528e9d6fe1f6
Subnet created: subnet-0aa9ba47908c511ed
aws ecs list-clusters
aws ecs delete-cluster --cluster="arn:aws:ecs:ap-southeast-1:861481479208:cluster/primexdemo7"
Comments
Post a Comment