You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
716 B

kind: pipeline
name: MyService
steps:
- name: Build
image: docker-0.unsee.tech/golang:1.23.2
environment:
GO111MODULE: on
commands:
- echo "Building the Go project with Test Mode"
- go build -o myapp -ldflags "-X main.RunMode=test"
- ls -lh
- ./prdUploader
- name: Deploy to Docker Container
image: docker
commands:
- echo "Stopping and removing the old container if it exists"
- docker stop product_uploader || true
- docker rm product_uploader || true
- echo "Deploying the application to a new Docker container"
- docker build -t prdUploader:test .
- docker run -d -p 11000:11000 --name product_uploader prdUploader:test