Last active
June 4, 2023 13:09
-
-
Save sintret/a6dd1efd5cb15c19ca91c3ef5397b38b to your computer and use it in GitHub Desktop.
pipelines for bitbucket
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| CONNECT TO PIPELINE BITBUCKET | |
| ------------------- | |
| Go to settings then click SSH Keys then generate | |
| Copy your ssh-rsa then | |
| input your domain and fetch | |
| LINUX COMMAND | |
| ------------ | |
| echo "YOUR_SSH [email protected]" >> ~/.ssh/authorized_keys | |
| echo "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCpfGtp1MTxOrp9Ce9V0xNhJWVcGsX2Ukm7rAbfdLIaiDs2ckeV2aufzz1Mki94qj6n1xW6dhfGIysT/Jn6xGgllsVB4w+QahIpq+EpBKAbHC2bGVSwb4dHLdHnB4TaR3X0AbMclptRCrrrkS56upR5wpBuiCs4V0tA8fzjXIUbHwgxVIaXKxNkpRrqozB9wbMfzlhSp1nuXgNWUYpatc06U66cpXdQTOXjJnoKRHdGq9efyYoi92S/lqeqY4O91ZEbL57GqyO/HHEUalzIiCq5qLg71VF/0rVVs1HudPlCW3UFiERMX0e2TVh6GbUW0H9fhTdBFwqkSem7pHbmk6qfXjGzcs77SLKNuMBWiX3bESHwoCdMZjtyupnOjSa0UDRxSOHpYnAGN+oVkmZ3wQAgm2dmAzFSfxhM6ExEC6edib9D3eRYPKsROHu+Lb5NeJy9gIWSpT15X39vc0dvM0YeAzJ+NYdejTbDIN234H4aN/u57pKWNw9ExXp3Z+jZF7E= [email protected]" >> ~/.ssh/authorized_keys | |
| my_known_host | |
| ============= | |
| yourdomain ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQCpfGtp1MTxOrp9Ce9V0xNhJWVcGsX2Ukm7rAbfdLIaiDs2ckeV2aufzz1Mki94qj6n1xW6dhfGIysT | |
| bitbucket-pipelines.yml | |
| ====================== | |
| # This is a sample build configuration for Docker. | |
| # Check our guides at https://confluence.atlassian.com/x/O1toN for more examples. | |
| # Only use spaces to indent your .yml configuration. | |
| # ----- | |
| # You can specify a custom docker image from Docker Hub as your build environment. | |
| # https://community.atlassian.com/t5/Answers-Developer-Questions/Pipelines-deploy-with-rsync/qaq-p/474381 | |
| image: atlassian/default-image:2 | |
| pipelines: | |
| default: | |
| - step: | |
| services: | |
| - docker | |
| script: # Modify the commands below to build your repository. | |
| - git diff --name-only --diff-filter=ADMR @~..@ > diff.txt | |
| - apt-get update && apt-get install -y grep | |
| - mkdir -p ~/.ssh | |
| - cat my_known_hosts >> ~/.ssh/known_hosts | |
| - if [ $BITBUCKET_BRANCH == 'master' ]; then | |
| - rsync -avzc --stats --delete --exclude-from=deployment-exclude-list.txt . [email protected]:/home/school/www/ | |
| - fi |
please install rsync in your linux platform
certbot --nginx --agree-tos --register-unsafely-without-email -d binamarga.tentangmu.com
ln -s /etc/nginx/sites-available/texcare_test.conf /etc/nginx/sites-enabled
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
if error bash: /root/.ssh/authorized_keys: Operation not permitted
chattr -i authorized_keys