BagelsForTuesday
BagelsForTuesday
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
Once again, appreciate your help so far
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
Alright will take some time to chew on this and see if I can see whats up, I'll be sure to update you on here if I do figure it out or if I don't
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
of course the repro attempt actually works RIP
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
Will do, let me try and put something together!
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
ah nice, good to know
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
I was using the railway cli to test, does that also ignore .gitignore when building? (wasn't sure) but I see your point, but just for sanity, I removed both but the issue remains
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
Dang, I tried ls -la /app/internal/cmd && ls -la /app/internal/cmd/colosseum inside the Dockerfile and somehow that dir is actually not there, super weird but nothing in the dockerignore and works just fine locally...
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
🤞
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
I wouldn't be able to share the repo but I can promise that the structure is correct
e.g:

├── internal

│   ├── cmd
│   │   └── colosseum
│   │   └── main.go
e.g:

├── internal

│   ├── cmd
│   │   └── colosseum
│   │   └── main.go
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
appreciate the quick response, FWIW, I have tried things like deleting the project/service in case there was some weird caching of the context etc but no luck
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
yeah its a weird one
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
hmmm
#9 [5/6] COPY . .
#9 DONE 0.0s

#10 [6/6] RUN go build -o colosseum ./...

#10 0.698 go: cannot write multiple packages to non-directory colosseum

#10 ERROR: process "/bin/sh -c go build -o colosseum ./..." did not complete successfully: exit code: 1
#9 [5/6] COPY . .
#9 DONE 0.0s

#10 [6/6] RUN go build -o colosseum ./...

#10 0.698 go: cannot write multiple packages to non-directory colosseum

#10 ERROR: process "/bin/sh -c go build -o colosseum ./..." did not complete successfully: exit code: 1
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
to clarify
RUN go build -o colosseum ./...
RUN go build -o colosseum ./...
?
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
[6/6] RUN go build -o colosseum ./internal/cmd/colosseum:

0.294 stat /app/internal/cmd/colosseum: directory not found

-----
[6/6] RUN go build -o colosseum ./internal/cmd/colosseum:

0.294 stat /app/internal/cmd/colosseum: directory not found

-----
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
ofc...
# Use the specific Go 1.20 image as the base image
FROM golang:1.20

# Set the working directory inside the container
WORKDIR /app

# Copy the Go module files to the working directory
COPY go.mod go.sum ./

# Download the Go module dependencies
RUN go mod download

# Copy the rest of the application source code to the working directory
COPY . .

# Build the Go application
RUN go build -o colosseum ./internal/cmd/colosseum

# Set the port number that the container should expose
ENV PORT 8080

# Expose the port on which the application will listen
EXPOSE $PORT

# Set the command to run when the container starts
CMD ["./colosseum"]
# Use the specific Go 1.20 image as the base image
FROM golang:1.20

# Set the working directory inside the container
WORKDIR /app

# Copy the Go module files to the working directory
COPY go.mod go.sum ./

# Download the Go module dependencies
RUN go mod download

# Copy the rest of the application source code to the working directory
COPY . .

# Build the Go application
RUN go build -o colosseum ./internal/cmd/colosseum

# Set the port number that the container should expose
ENV PORT 8080

# Expose the port on which the application will listen
EXPOSE $PORT

# Set the command to run when the container starts
CMD ["./colosseum"]
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
service id: f4b778dc-aa7e-4d96-acf0-53e538f72d79
39 replies
RRailway
Created by BagelsForTuesday on 9/2/2023 in #✋|help
Go Deploy Gone Wrong
3a924444-5f7c-477b-a993-438ff0417e6d
39 replies
RRailway
Created by BagelsForTuesday on 7/17/2023 in #✋|help
Is it possible to set resource limits at the service level?
That would be great if possible
19 replies
RRailway
Created by BagelsForTuesday on 7/17/2023 in #✋|help
Is it possible to set resource limits at the service level?
Understood, thanks for weighing in on this, much appreciated
19 replies