test
This commit is contained in:
parent
ea6609e5a8
commit
6efc06a551
25
action.yml
25
action.yml
@ -8,12 +8,19 @@ runs:
|
|||||||
with:
|
with:
|
||||||
args: dotnet publish -r linux-x64 -c Release --self-contained -o dist -p:AssemblyName=App
|
args: dotnet publish -r linux-x64 -c Release --self-contained -o dist -p:AssemblyName=App
|
||||||
|
|
||||||
- shell: sh
|
- uses: docker://ubuntu:latest
|
||||||
run: |
|
with:
|
||||||
echo "FROM mcr.microsoft.com/dotnet/runtime:7.0" > Dockerfile
|
entrypoint: "/bin/bash"
|
||||||
echo "COPY dist /home" >> Dockerfile
|
args: |
|
||||||
echo "WORKDIR /home" >> Dockerfile
|
-c 'echo "FROM mcr.microsoft.com/dotnet/runtime:7.0" > Dockerfile'
|
||||||
echo "ENTRYPOINT [\"./App\"]" >> Dockerfile
|
-c 'echo "COPY dist /home" >> Dockerfile'
|
||||||
docker build -t ${{env.DOCKER_REGISTRY}}/${{github.repository}}:${{ github.ref_name }} .
|
-c 'echo "WORKDIR /home" >> Dockerfile'
|
||||||
docker login ${{env.DOCKER_REGISTRY}} -u ${{env.DOCKER_USER}} -p ${{env.DOCKER_PASS}}
|
-c 'echo "ENTRYPOINT [\"./App\"]" >> Dockerfile'
|
||||||
docker push ${{env.DOCKER_REGISTRY}}/${{github.repository}}:${{ github.ref_name }}
|
|
||||||
|
- uses: docker://docker:git
|
||||||
|
with:
|
||||||
|
entrypoint: "/bin/bash"
|
||||||
|
args: |
|
||||||
|
-c 'docker build -t ${{env.DOCKER_REGISTRY}}/${{github.repository}}:${{ github.ref_name }} .'
|
||||||
|
-c 'docker login ${{env.DOCKER_REGISTRY}} -u ${{env.DOCKER_USER}} -p ${{env.DOCKER_PASS}}'
|
||||||
|
-c 'docker push ${{env.DOCKER_REGISTRY}}/${{github.repository}}:${{ github.ref_name }}'
|
Loading…
Reference in New Issue
Block a user