https://pulumi.com logo
#getting-started
Title
# getting-started
d

dry-byte-5648

08/28/2023, 9:07 AM
Why is ports an array if we can only give one?
Copy code
let service = new cloud.Service("pulumi-nginx", {
    containers: {
        nginx: {
            build: "./app",
            memory: 128,
            ports: [{ 
                port: 80, 
                protocol: 'http', 
                external: true 
            },
            { 
                port: 81, 
                protocol: 'http', 
                external: true 
            }],
        },
    },
    replicas: 1
});
" Error: Only one port can currently be exposed per Service."