This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-05-28
Channels
- # aws (1)
- # babashka (113)
- # beginners (41)
- # cider (9)
- # cljdoc (15)
- # cljs-dev (8)
- # cljsrn (5)
- # clojure (113)
- # clojure-australia (4)
- # clojure-europe (40)
- # clojure-nl (8)
- # clojure-taiwan (1)
- # clojure-uk (60)
- # clojurescript (59)
- # code-reviews (2)
- # conjure (1)
- # datahike (12)
- # events (1)
- # jobs (1)
- # kaocha (4)
- # lsp (24)
- # luminus (19)
- # malli (4)
- # off-topic (28)
- # pathom (10)
- # philosophy (1)
- # portal (6)
- # re-frame (3)
- # reagent (9)
- # remote-jobs (1)
- # shadow-cljs (31)
- # sql (24)
- # tools-deps (6)
- # xtdb (14)
:rolling_on_the_floor_laughing:
It would be a poet. A verbose poet.
I don't suppose anyone has experience with simple CI/CD for luminus/docker-compose/gitlab/digitalocean?
I agree that the Docker docs are pretty terrible, but Docker is quite a useful tool for projects large and small.
@kimo not really, but I'm trying to limit myself only to Docker commands for my current project, and Makefiles for CI. If those aren't powerful enough for you, you might want to check out Salt Stack. It's docs are also pretty terrible but the examples reveal that it actually has quite a simple paradigm. Unfortunately it suffers from the same esoteric naming convention that all those tools suffer from.
Here's my current script for initialising a db:
var path = require('path');
var sh = require('shelljs');
var dataDir = path.resolve(__dirname, '../data/pg');
var settings = [
"-e POSTGRES_HOST_AUTH_METHOD=trust" // Trust all connections (local dev only)
, "-p 3201:5432"
, "-v ${dataDir}:/var/lib/postgresql/data"
]
sh.exec(`docker run --name pg ${settings.join(' ')} -d postgres:11-alpine`)
> I'm trying to limit myself only to Docker commands for my current project, and Makefiles for CI I'm so thankful this is becoming a trend. (Although I think using podman and avoiding the client/server model of docker is better.)
This https://gitlab.com/tvaughan/docker-flask-starterkit is a project I created a number of years ago that was a port of a proprietary project I developed in Clojure (although it's language agnostic). It follows this approach, as well as includes everything required to provision a complete environment in aws and run tests in a nearly identical setup locally (traefik is used in-place of an ELB, for example)
I don't use Dockerfiles to build the project resources, instead using normal build tools to do that in our CI/CD pipeline, then having the Dockerfile copy the built artifacts into the image. That way we've got a reproducible artifact that's easy to deploy to ECS/wherever.
@futuro @tvaughan @d.marrs @simongray Thanks for the tips, I'll go over these. Rich should do a new "Spec-ulation" about CI/CD, haha.
A question for the JS experts, is it possible to pass the JS AST directly to the JS engine and skip the parsing step? Do the JS engines expose such an API? (couldn't gather much from their docs)
Asking because, if that was possible, why not just parse CLJS to the JS AST and send it to the browser?
I would expect each JS engine to have its own somewhat unique AST (but I haven’t looked at the source of any of them). But, yeah, WASM would probably make more sense as a target if you’re trying to avoid transpilation to JS.
But if CLJS had to be compiled to wasm, then all the memory management semantics will have to be taken care of
I was wondering if it could understand an AST like https://github.com/acornjs/acorn, then it would be viable to emit such an AST from the CLJS source and let the JS engines take care of the mem management
That’s about what I expected 🙂
Hey @UMPJRJU9E, in a context of clojurescript, you can thin about "clojure -> GCC IR" https://github.com/google/closure-compiler/wiki/Writing-Compiler-Pass Google Closure Compiler has an internal AST in pratice, it's just another wired, internal, and unstable js AST, so you may run into breaking changes between GCC releases