Update Dockerfile #172
This file contains 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
name: CloudShell | |
on: | |
push: | |
branches: [ main ] | |
schedule: | |
- cron: '0 0 1 * *' | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
if: github.repository == 'ConchbrainClub/CloudShell' | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Build the Docker image | |
run: docker build . --file Dockerfile --tag cloudshell:latest | |
- name: Push image to DockerHub | |
run: | | |
docker login -u lixinyang -p ${{ secrets.DOCKERHUB_PASSWORD }} | |
docker tag cloudshell:latest lixinyang/cloudshell:latest | |
docker push lixinyang/cloudshell:latest | |
docker logout | |
- name: Push image to Aliyun | |
run: | | |
docker login -u=lllxy啊啊啊 -p ${{ secrets.DOCKERHUB_PASSWORD }} registry.cn-shenzhen.aliyuncs.com | |
docker tag cloudshell:latest registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:latest | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:latest | |
docker logout | |
container-dockerhub: | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Build UserContainer | |
run: | | |
cd ./container | |
docker build -t lixinyang/cloudshell:ubuntu ./ubuntu | |
docker build -t lixinyang/cloudshell:centos ./centos | |
docker build -t lixinyang/cloudshell:debian ./debian | |
docker build -t lixinyang/cloudshell:alpine ./alpine | |
docker build -t lixinyang/cloudshell:archlinux ./archlinux | |
docker build -t lixinyang/cloudshell:kali ./kali | |
docker build -t lixinyang/cloudshell:fedora ./fedora | |
docker build -t lixinyang/cloudshell:opensuse ./opensuse | |
docker build -t lixinyang/cloudshell:rockylinux ./rockylinux | |
cd .. | |
- name: Push image to DockerHub | |
run: | | |
docker login -u lixinyang -p ${{ secrets.DOCKERHUB_PASSWORD }} | |
docker push lixinyang/cloudshell:ubuntu | |
docker push lixinyang/cloudshell:centos | |
docker push lixinyang/cloudshell:debian | |
docker push lixinyang/cloudshell:alpine | |
docker push lixinyang/cloudshell:archlinux | |
docker push lixinyang/cloudshell:kali | |
docker push lixinyang/cloudshell:fedora | |
docker push lixinyang/cloudshell:opensuse | |
docker push lixinyang/cloudshell:rockylinux | |
docker logout | |
container-aliyun: | |
needs: build | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Build UserContainer | |
run: | | |
cd ./container | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:ubuntu ./ubuntu | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:centos ./centos | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:debian ./debian | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:alpine ./alpine | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:archlinux ./archlinux | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:kali ./kali | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:fedora ./fedora | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:opensuse ./opensuse | |
docker build -t registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:rockylinux ./rockylinux | |
cd .. | |
- name: Push image to Aliyun | |
run: | | |
docker login -u=lllxy啊啊啊 -p ${{ secrets.DOCKERHUB_PASSWORD }} registry.cn-shenzhen.aliyuncs.com | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:ubuntu | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:centos | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:debian | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:alpine | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:archlinux | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:kali | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:fedora | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:opensuse | |
docker push registry.cn-shenzhen.aliyuncs.com/lllxy/cloudshell:rockylinux | |
docker logout |